summaryrefslogtreecommitdiff
path: root/indra/llmessage
AgeCommit message (Collapse)Author
2020-10-09SL-14078 No point in verifying display name cap each frameAndrey Kleshchev
Convoluted due to multiple workarounds. Might be a good idea to spend some time refactoring this, but for now just trottled checks.
2020-10-08DRTVWR-510 remove all LL_SOLARIS conditionalsDave Houlton
2020-10-06Add in the C++ filesystem based cache and clean up some indempotent ↵Callum Prentice
functions in llfilesystem
2020-10-01SL-14037 BugSplat Crash #646590: Enqueue failed in AISAndrey Kleshchev
2020-09-28Merge branch 'master' into DRTVWR-513-maintAndrey Lihatskiy
# Conflicts: # indra/newview/llgroupmgr.cpp
2020-09-24Complete the change from lldiskcache -> llfilesystem and then addition of ↵Callum Prentice
new lldiskcache implementation
2020-09-22Merge branch 'master' into DRTVWR-519Callum Prentice
2020-09-17The folder where the disk cache lives was originally renamed from llvfs to ↵Callum Prentice
llcache but @henri's suggestion that that doesn't reflect the other files in the same place and it should be llfilesystem is a good one so I changed it over
2020-09-16Renamed the references to LLVFile and llvfile.* source code plus cmake ↵Callum Prentice
scripts to use a different name - lldiskcache - since that more closely resembles what it is (or will be) now that the VFA is no more
2020-09-16First part of change to remove LLVFS from the Viewer. Consists of code ↵Callum Prentice
changes to remove LLVFS and LLVFSThread classes along with the associated source files. The existing llvfs folder is renamed to llcache. Also includes changes to CMake script in many places to reflect changes. Eventually, llvfile source file and class will be renamed but that is not in this change.
2020-09-16Check existence of local files instead of checking VFSMnikolenko Productengine
2020-09-02SL-13891 Coroutine creation was requested on exitAndrey Kleshchev
2020-08-28SL-13555 'Second Life quit unexpectedly' error messageAndrey Kleshchev
2020-08-28SL-13811 Crash on coroprocedureAndrey Kleshchev
2020-08-20SL-13811 Crash on coroprocedureAndrey Kleshchev
Coroprosedure should stop on 'stop' exception
2020-08-18Merge branch 'master' into DRTVWR-513-maintAndrey Lihatskiy
# Conflicts: # indra/newview/llimprocessing.cpp # indra/newview/llviewerjoystick.cpp # indra/newview/llviewermenufile.cpp
2020-08-18SL-13783 Workaround for enqueueCoprocedure() crash #2Andrey Kleshchev
2020-08-17Merged in SL-13783 and SL-13789Andrey Kleshchev
2020-08-17SL-13783 Workaround for enqueueCoprocedure() crash with asset storageAndrey Kleshchev
2020-08-11Merge branch 'master' into DRTVWR-513-maintAndrey Lihatskiy
2020-08-11Merge branch 'DRTVWR-501-maint' into DRTVWR-503-maintAndrey Lihatskiy
# Conflicts: # indra/cmake/DirectX.cmake # indra/newview/llviewerparcelmedia.cpp # indra/newview/viewer_manifest.py
2020-07-29Merge branch 'DRTVWR-476' into DRTVWR-501-maintAndrey Kleshchev
2020-07-24SL-13679 Event pump DupListenerName crash at loginAndrey Kleshchev
2020-07-22Remove redundant LL_EXSTAT_ from enums.Nicky Dasmijn
2020-07-22LLExtStat had been a S32, this wasn't right, as some of the constants lead ↵Nicky Dasmijn
to integer overflow: const LLExtStat LL_EXSTAT_RES_RESULT = 2L<<30; const LLExtStat LL_EXSTAT_VFS_RESULT = 3L<<30; This shifts into the sign bit and clang gets (rightfully) upset about this. LLExtStatus needs to be at least of type U32 to remedy this problem, but while at it it makes sense to turn it into what it is: An enum. Turning it into a class enum has the added benefit we get type safety for mostly free. Which incidentally turned up a problem right away: A call to removeAndCallbackPendingDownloads had status and extstatus reversed and thus was wrong.
2020-07-21Merge branch 'master' into DRTVWR-513-maintAndrey Lihatskiy
# Conflicts: # indra/llcommon/llerror.cpp # indra/newview/llappviewerwin32.cpp # indra/newview/llimprocessing.cpp # indra/newview/llviewerjoystick.cpp
2020-06-05SL-12748 Blocked username displays old name after name changeAndrey Kleshchev
2020-05-29SL-13348 Thread crashing singleton #1Andrey Kleshchev
2020-05-27DRTVWR-476: Add "Socket" debug log output for socket operations.Nat Goodspeed
Enable the body of the existing ll_debug_socket() function (on Mac as well as Linux), but using tag "Socket" so you can turn on its log messages without emitting *all* debug messages.
2020-05-21DRTVWR-476: Support older compilers with LockMessageReader.Nat Goodspeed
2020-05-20DRTVWR-476: Fix LLCoprocedurePool::enqueueCoprocedure() shutdown crash.Nat Goodspeed
2020-05-19Make sure coproc gets destroyed after each iteration.Nicky Dasmijn
Making coproc scoped to the for loop will make sure the destructor gets called every loop iteration. Keeping it's scope outside the for loop means the pointer keeps valid till the next assigment that happens inside pop_wait_for when it gets assigned a new value. Triggering the dtor inside pop_wait_for can lead to deadlock when inside the dtor a coroutine tries to call enqueueCoprocedure (this happens). enqueueCoprocedure then will try to grab the lock for try_push but this lock is still held by pop_wait_for.
2020-05-19DRTVWR-476: Clean up reverting to boost::fibers::buffered_channel.Nat Goodspeed
2020-05-19DRTVWR-476: Revert "Use LLThreadSafeQueue, not boost::fibers::buffered_channel."Nat Goodspeed
This reverts commit bf8aea5059f127dcce2fdf613d62c253bb3fa8fd. Try boost::fibers::buffered_channel again with Boost 1.72.
2020-05-14DRTVWR-476, SL-12204: Fix crash in Marketplace Listings.Nat Goodspeed
The observed crash was due to sharing a stateful global resource (the global LLMessageSystem instance) between different tasks. Specifically, a coroutine sets its mMessageReader one way, expecting that value to persist until it's done with message parsing, but another coroutine sneaks in at a suspension point and sets it differently. Introduce LockMessageReader and LockMessageChecker classes, which must be instantiated by a consumer of the resource. The constructor of each locks a coroutine-aware mutex, so that for the lifetime of the lock object no other coroutine can instantiate another. Refactor the code so that LLMessageSystem::mMessageReader can only be modified by LockMessageReader, not by direct assignment. mMessageReader is now an instance of LLMessageReaderPointer, which supports dereferencing and comparison but not assignment. Only LockMessageReader can change its value. LockMessageReader addresses the use case in which the specific mMessageReader value need only persist for the duration of a single method call. Add an instance in LLMessageHandlerBridge::post(). LockMessageChecker is a subclass of LockMessageReader: both lock the same mutex. LockMessageChecker addresses the use case in which the specific mMessageReader value must persist across multiple method calls. Modify the methods in question to require a LockMessageChecker instance. Provide LockMessageChecker forwarding methods to facilitate calling the underlying LLMessageSystem methods via the LockMessageChecker instance. Add LockMessageChecker instances to LLAppViewer::idleNetwork(), a couple cases in idle_startup() and LLMessageSystem::establishBidirectionalTrust().
2020-05-06DRTVWR-476: Merge branch 'master' of lindenlab/viewer into DRTVWR-476-boost-1.72Nat Goodspeed
2020-05-05Merge branch 'DRTVWR-501-maint' into DRTVWR-503-maintAndrey Lihatskiy
# Conflicts: # indra/newview/llinventorybridge.cpp # indra/newview/llinventorypanel.cpp # indra/newview/lltexturectrl.cpp # indra/newview/skins/default/xui/de/floater_texture_ctrl.xml # indra/newview/skins/default/xui/es/floater_texture_ctrl.xml # indra/newview/skins/default/xui/fr/floater_texture_ctrl.xml # indra/newview/skins/default/xui/it/floater_texture_ctrl.xml # indra/newview/skins/default/xui/ja/floater_texture_ctrl.xml # indra/newview/skins/default/xui/pt/floater_texture_ctrl.xml # indra/newview/skins/default/xui/ru/floater_texture_ctrl.xml # indra/newview/skins/default/xui/tr/floater_texture_ctrl.xml # indra/newview/skins/default/xui/zh/floater_texture_ctrl.xml
2020-04-20Merge branch 'master' into DRTVWR-500Andrey Lihatskiy
# Conflicts: # indra/newview/pipeline.cpp
2020-03-25DRTVWR-476: Use LLThreadSafeQueue::close() to shut down coprocs.Nat Goodspeed
The tactic of pushing an empty QueuedCoproc::ptr_t to signal coprocedure close only works for LLCoprocedurePools with a single coprocedure (e.g. "Upload" and "AIS"). Only one coprocedureInvokerCoro() coroutine will pop that empty pointer and shut down properly -- the rest will continue waiting indefinitely. Rather than pushing some number of empty pointers, hopefully enough to notify all consumer coroutines, close() the queue. That will notify as many consumers as there may be. That means catching LLThreadSafeQueueInterrupt from popBack(), instead of detecting empty pointer. Also, if a queued coprocedure throws an exception, coprocedureInvokerCoro() logs it as before -- but instead of rethrowing it, the coroutine now loops back to wait for more work. Otherwise, the number of coroutines servicing the queue dwindles.
2020-03-25DRTVWR-476, SL-12197: Don't throw Stopping from main coroutine.Nat Goodspeed
The new LLCoros::Stop exception is intended to terminate long-lived coroutines -- not interrupt mainstream shutdown processing. Only throw it on an explicitly-launched coroutine. Make LLCoros::getName() (used by the above test) static. As with other LLCoros methods, it might be called after the LLCoros LLSingleton instance has been deleted. Requiring the caller to call instance() implies a possible need to also call wasDeleted(). Encapsulate that nuance into a static method instead.
2020-03-25DRTVWR-476: Introduce LLCoprocedureManager::close(). Use in tests.Nat Goodspeed
The new close(void) method simply acquires the logic from ~LLCoprocedureManager() (which now calls close()). It's useful, even if only in test programs, to be able to shut down all existing LLCoprocedurePools without having to name them individually -- and without having to destroy the LLCoprocedureManager singleton instance. Deleting an LLSingleton should be done only once per process, whereas test programs want to reset the LLCoprocedureManager after each test.
2020-03-25DRTVWR-476: Use LLThreadSafeQueue, not boost::fibers::buffered_channel.Nat Goodspeed
We've observed buffered_channel::try_push() hanging, which seems very odd. Try our own LLThreadSafeQueue instead.
2020-03-25DRTVWR-476: Manually count items in LLCoprocedurePool's pending queue.Nat Goodspeed
Reinstate LLCoprocedureManager::countPending() and count() methods. These were removed because boost::fibers::buffered_channel has no size() method, but since all users run within a single thread, it works to increment and decrement a simple counter. Add count information and max queue size to log messages.
2020-03-25DRTVWR-476: Use shared_ptr to manage lifespan of coprocedure queue.Nat Goodspeed
Since the consuming coroutine LLCoprocedurePool::coprocedureInvokerCoro() has been observed to outlive the LLCoprocedurePool instance that owns the CoprocQueue_t, closing that queue isn't enough to keep the coroutine from crashing at shutdown: accessing a deleted CoprocQueue_t is fatal whether or not it's been closed. Make LLCoprocedurePool store a shared_ptr to a heap CoprocQueue_t instance, and pass that shared_ptr by value to consuming coroutines. That way the CoprocQueue_t instance is guaranteed to live as long as the last interested party.
2020-03-25DRTVWR-476: Back out changeset 40c0c6a8407d ("final" LLApp listener)Nat Goodspeed
2020-03-25DRTVWR-476: Pump coroutines a few more times when we start quitting.Nat Goodspeed
By the time "LLApp" listeners are notified that the app is quitting, the mainloop is no longer running. Even though those listeners do things like close work queues and inject exceptions into pending promises, any coroutines waiting on those resources must regain control before they can notice and shut down properly. Add a final "LLApp" listener that resumes ready coroutines a few more times. Make sure every other "LLApp" listener is positioned before that new one.
2020-03-25DRTVWR-476: Terminate long-lived coroutines to avoid shutdown crash.Nat Goodspeed
Add LLCoros::TempStatus instances around known suspension points so printActiveCoroutines() can report what each suspended coroutine is waiting for. Similarly, sprinkle checkStop() calls at known suspension points. Make LLApp::setStatus() post an event to a new LLEventPump "LLApp" with a string corresponding to the status value being set, but only until ~LLEventPumps() -- since setStatus() also gets called very late in the application's lifetime. Make postAndSuspendSetup() (used by postAndSuspend(), suspendUntilEventOn(), postAndSuspendWithTimeout(), suspendUntilEventOnWithTimeout()) add a listener on the new "LLApp" LLEventPump that pushes the new LLCoros::Stopping exception to the coroutine waiting on the LLCoros::Promise. Make it return the new LLBoundListener along with the previous one. Accordingly, make postAndSuspend() and postAndSuspendWithTimeout() store the new LLBoundListener returned by postAndSuspendSetup() in a LLTempBoundListener (as with the previous one) so it will automatically disconnect once the wait is over. Make each LLCoprocedurePool instance listen on "LLApp" with a listener that closes the queue on which new work items are dispatched. Closing the queue causes the waiting dispatch coroutine to terminate. Store the connection in an LLTempBoundListener on the LLCoprocedurePool so it will disconnect automatically on destruction. Refactor the loop in coprocedureInvokerCoro() to instantiate TempStatus around the suspending call. Change a couple spammy LL_INFOS() calls to LL_DEBUGS(). Give all logging calls in that module a "CoProcMgr" tag to make it straightforward to re-enable the LL_DEBUGS() calls as desired.
2020-03-25DRTVWR-476: Re-enable an llcoproceduremanager_test case.Nat Goodspeed
Use new Sync class to make the driving logic wait for the coprocedure to run.
2020-03-25[DRTVWR-476] - temp fix to test. comment it out. access violation in releaseAnchor
2020-03-25[DRTVWR-476] - temp fix to a testAnchor