Commit Graph

90 Commits (ed67ca001cee84b6771bcc5efafd27f8a40b35f5)

Author SHA1 Message Date
Ansariel 8ac67e5476 Merge branch 'DRTVWR-563' of https://bitbucket.org/lindenlab/viewer 2022-06-18 15:53:35 +02:00
Nat Goodspeed 50dca86f64 SL-17483: Recast LLImageDecodeThread as a facade for ThreadPool.
Remove all references to LLQueuedThread (but emulate a couple bits of its API
such as handle_t and getPending()).

Migrate ImageRequest into llimageworker.cpp. It has never been part of
LLImageDecodeThread's public API. Remove ImageRequest tests.

Remove all references to LLImageDecodeThread::pause(). The idea of pausing
another thread is bizarre to me, and LLThreadPool has no such operation. Nor
does it have an abortRequest().
2022-06-09 12:06:23 -04:00
Ansariel 7427b46ea5 Merge branch 'DRTVWR-546' of https://bitbucket.org/lindenlab/viewer
# Conflicts:
#	.gitignore
#	indra/cmake/Copy3rdPartyLibs.cmake
#	indra/llcommon/llcommon.cpp
#	indra/llcommon/llerror.cpp
#	indra/llcommon/llprofiler.h
#	indra/llcommon/llthread.cpp
#	indra/llimage/llimageworker.cpp
#	indra/llprimitive/llmodel.h
#	indra/llrender/llfontgl.cpp
#	indra/llrender/llfontgl.h
#	indra/llrender/llgl.cpp
#	indra/llrender/llvertexbuffer.cpp
#	indra/llrender/llvertexbuffer.h
#	indra/llwindow/llwindowmacosx.h
#	indra/llwindow/llwindowwin32.cpp
#	indra/llwindow/llwindowwin32.h
#	indra/newview/app_settings/settings.xml
#	indra/newview/llappviewer.cpp
#	indra/newview/llappviewer.h
#	indra/newview/lldrawpoolavatar.cpp
#	indra/newview/lldrawpoolavatar.h
#	indra/newview/lldynamictexture.cpp
#	indra/newview/llfloatermodelpreview.cpp
#	indra/newview/llimview.cpp
#	indra/newview/llmeshrepository.h
#	indra/newview/llmodelpreview.cpp
#	indra/newview/llnetmap.cpp
#	indra/newview/llskinningutil.cpp
#	indra/newview/llskinningutil.h
#	indra/newview/llspatialpartition.cpp
#	indra/newview/llteleporthistory.cpp
#	indra/newview/llviewerdisplay.cpp
#	indra/newview/llviewerobject.cpp
#	indra/newview/llviewerobjectlist.cpp
#	indra/newview/llviewertexture.cpp
#	indra/newview/llviewertexturelist.cpp
#	indra/newview/llviewerwindow.cpp
#	indra/newview/llvoicevivox.cpp
#	indra/newview/llvosky.cpp
#	indra/newview/llvovolume.cpp
2021-11-12 15:21:52 +01:00
Dave Parks 675514bdb3 SL-16093 Don't force the console window to be open on developer builds because it causes frame stalls while logging. 2021-09-27 23:56:06 +00:00
Nicky Dasmijn 27715d4d03 Merge remote-tracking branch 'll/d476' into fs-eep-vs2017-d476 2020-05-21 06:54:02 +02:00
Nat Goodspeed 962ccb4f01 DRTVWR-476: Facilitate debugging test programs with logging.
On Mac, even if you run a test program with --debug or set LOGTEST=DEBUG, it
won't log to stderr if you're filtering build output or running the build in
an emacs compile buffer. This is because, on Mac, a viewer launched by mouse
rather than from the command line is passed a stderr stream that ultimately
gets logged to the system Console. The shouldLogToStderr() function is
intended to avoid spamming the Console with the (voluminous) viewer log
output. It tests whether stderr isatty() and, if not, suppresses calling
LLError::logToStderr().

This makes debugging test programs using log output trickier than necessary.
Change shouldLogToStderr() to permit logging when either stderr isatty() or is
a pipe. The original intention is preserved in that empirically, a viewer
launched by mouse is passed a stderr stream identified as a character device
rather than as a pipe.

Also introduce SetEnv, a class that facilitates setting (e.g.) LOGTEST=DEBUG
for specific test programs without setting it for all test programs in the
build. Using the constructor for a static object means you can set environment
variables before main() is entered, which is important because it's the main()
function in test.cpp that acts on the LOGTEST and LOGFAIL environment
variables.

These changes make it unnecessary to retain the temporary change in test.cpp
to force LOGTEST to DEBUG.
2020-04-03 10:46:17 -04:00
Nat Goodspeed dc07509f29 DRTVWR-476: Cherry-pick debug aids from commit 77b0c53 (fiber-mutex) 2020-04-03 10:38:53 -04:00
Nat Goodspeed 39f4acd921 DRTVWR-476: Conflate LOGFAIL env var empty with completely unset.
Sometimes it's useful to be able to temporarily override an existing LOGFAIL
setting in the current environment. It's far more convenient to prepend
LOGFAIL='' to a command than to 'unset LOGFAIL' as a whole separate command --
and then remember to restore its previous value.
2020-03-25 19:07:22 -04:00
Nat Goodspeed 6b70493ddb DRTVWR-476: Make test program --debug switch work like LOGTEST=DEBUG.
The comments within indra/test/test.cpp promise that --debug is, in fact, like
LOGTEST=DEBUG. Until now, that was a lie. LOGTEST=level displayed log output
on stderr as well as in testprogram.log, while --debug did not.

Add LLError::logToStderr() function, and make initForApplication() (i.e.
commonInit()) call that instead of instantiating RecordToStderr inline. Also
call it when test.cpp recognizes --debug switch.

Remove the mFileRecorder, mFixedBufferRecorder and mFileRecorderFileName
members from SettingsConfig. That tactic doesn't scale.

Instead, add findRecorder<RECORDER>() and removeRecorder<RECORDER>() template
functions to locate (or remove) a RecorderPtr to an object of the specified
subclass. Both are based on an underlying findRecorderPos<RECORDER>() template
function. Since we never expect to manage more than a handful of RecorderPtrs,
and since access to the deleted members is very much application setup rather
than any kind of ongoing access, a search loop suffices.

logToFile() uses removeRecorder<RecordToFile>() rather than removing
mFileRecorder (the only use of mFileRecorder).

logToFixedBuffer() uses removeRecorder<RecordToFixedBuffer>() rather than
removing mFixedBufferRecorder (the only use of mFixedBufferRecorder).

Make RecordToFile store the filename with which it was instantiated. Add a
getFilename() method to retrieve it. logFileName() is now based on
findRecorder<RecordToFile>() instead of mFileRecorderFileName (the only use of
mFileRecorderFileName).

Make RecordToStderr::mUseANSI a simple bool rather than a three-state enum,
and set it immediately on construction. Apparently the reason it was set
lazily was because it consults its own checkANSI() method, and of course
'this' doesn't acquire the leaf class type until the constructor has completed
successfully. But since nothing in checkANSI() depends on anything else in
RecordToStderr, making it static solves that problem.
2020-03-25 18:47:13 -04:00
Nicky 9335eded97 Merge with viewer-vs2107 2019-12-08 17:18:43 +01:00
Nicky 53354e3513 Merge. 2019-12-07 19:18:27 +01:00
Nat Goodspeed a8ef51170d DRTVWR-476: Conflate LOGFAIL env var empty with completely unset.
Sometimes it's useful to be able to temporarily override an existing LOGFAIL
setting in the current environment. It's far more convenient to prepend
LOGFAIL='' to a command than to 'unset LOGFAIL' as a whole separate command --
and then remember to restore its previous value.
2019-11-15 08:11:32 -05:00
Nat Goodspeed 7ed993913c Automated merge with ssh://bitbucket.org/lindenlab/viewer-release 2019-11-11 16:45:37 -05:00
Nicky fee98dac77 Merge with VS2017 2019-11-10 12:07:34 +01:00
Ansariel d79b79fbe2 Merge viewer-ordered-shutdown 2019-10-19 03:16:10 +02:00
Nat Goodspeed 18bb6d5d49 DRTVWR-476: Make test program --debug switch work like LOGTEST=DEBUG.
The comments within indra/test/test.cpp promise that --debug is, in fact, like
LOGTEST=DEBUG. Until now, that was a lie. LOGTEST=level displayed log output
on stderr as well as in testprogram.log, while --debug did not.

Add LLError::logToStderr() function, and make initForApplication() (i.e.
commonInit()) call that instead of instantiating RecordToStderr inline. Also
call it when test.cpp recognizes --debug switch.

Remove the mFileRecorder, mFixedBufferRecorder and mFileRecorderFileName
members from SettingsConfig. That tactic doesn't scale.

Instead, add findRecorder<RECORDER>() and removeRecorder<RECORDER>() template
functions to locate (or remove) a RecorderPtr to an object of the specified
subclass. Both are based on an underlying findRecorderPos<RECORDER>() template
function. Since we never expect to manage more than a handful of RecorderPtrs,
and since access to the deleted members is very much application setup rather
than any kind of ongoing access, a search loop suffices.

logToFile() uses removeRecorder<RecordToFile>() rather than removing
mFileRecorder (the only use of mFileRecorder).

logToFixedBuffer() uses removeRecorder<RecordToFixedBuffer>() rather than
removing mFixedBufferRecorder (the only use of mFixedBufferRecorder).

Make RecordToFile store the filename with which it was instantiated. Add a
getFilename() method to retrieve it. logFileName() is now based on
findRecorder<RecordToFile>() instead of mFileRecorderFileName (the only use of
mFileRecorderFileName).

Make RecordToStderr::mUseANSI a simple bool rather than a three-state enum,
and set it immediately on construction. Apparently the reason it was set
lazily was because it consults its own checkANSI() method, and of course
'this' doesn't acquire the leaf class type until the constructor has completed
successfully. But since nothing in checkANSI() depends on anything else in
RecordToStderr, making it static solves that problem.
2019-10-14 15:41:09 -04:00
Nat Goodspeed d10b06dc4f DRTVWR-493: When a test fails due to exception, display exception. 2019-08-19 10:00:09 -04:00
Nat Goodspeed adb3f447b3 DRTVWR-493: Introduce test catch_what(), catch_llerrs() functions.
Use them in place of awkward try/catch test boilerplate.
2019-08-10 20:33:59 -04:00
Ansariel 5532f87f80 Merge Firestorm LGPL 2018-11-16 00:09:19 +01:00
Nat Goodspeed f7e99f0db7 Automated merge with ssh://bitbucket.org/lindenlab/viewer-release 2018-11-14 16:17:36 -05:00
Ansariel ee34ea1f4b Merge viewer-bugsplat 2018-10-27 00:50:58 +02:00
Oz Linden d87cc1859f Modify logging so that the in-viewer console and stderr do not escape line breaks
Improve the implementation so that escaping is computed only once
2018-10-11 14:17:52 -04:00
Brad Payne (Vir Linden) 2b79663021 merge 2018-02-13 13:58:23 +00:00
Ansariel 76c179eeac Merge Firestorm LGPL 2018-02-12 23:20:50 +01:00
Ansariel 13ea9a242a Merge Firestorm LGPL 2017-10-11 20:30:12 +02:00
Brad Payne (Vir Linden) 299592e88e merge 2017-10-11 14:16:39 +01:00
Oz Linden d62ad1ef8a merge changes for 5.0.8-release 2017-10-11 09:13:55 -04:00
Ansariel 2d6314182b Merge Firestorm LGPL 2017-10-11 19:53:58 +02:00
Ansariel 01d8e7e347 Merge axon 2017-09-20 01:09:14 +02:00
Ansariel 615336a4d4 Merge viewer-neko 2017-09-07 21:49:12 +02:00
Brad Payne (Vir Linden) 2af5332e46 Added cycle_object_animations.lsl. Also change to test.cpp to see if it affects a g++ internal compiler error. 2017-06-30 21:59:39 +01:00
Ansariel 1baf1f5091 Merge Firestorm LGPL 2017-06-20 23:24:35 +02:00
Oz Linden d8be66c8e2 merge changes for 5.0.6-release 2017-06-20 17:05:53 -04:00
Ansariel e3a61bb4ce Merge LL viewer-release 5.0.6 2017-06-20 22:48:25 +02:00
andreykproductengine f8254a9d78 MAINT-7758 Fixed freeze on loading lsl scripts from unicode named windows folder. 2017-08-30 19:57:02 +03:00
Brad Payne (Vir Linden) b8e2c58cec no-op edit to force a rebuild 2017-05-24 13:08:12 +01:00
Ansariel c7473d4b99 Merge asset-http 2017-04-19 23:16:13 +02:00
Brad Payne (Vir Linden) 9311cc89ea DRTVWR-434 - trivial code change to trigger TC rebuild, also slight improvement to a log message 2017-04-11 13:45:43 -04:00
Ansariel 915496bbea Merge viewer-vivox 2017-03-21 22:14:02 +01:00
Oz Linden 0a7fd3686a Look for logcontrol-dev.xml in the user settings directory 2017-02-27 09:52:50 -05:00
Ansariel 3192fe832f Merge viewer-quickgraphics 2016-03-08 01:41:31 +01:00
Oz Linden c8726aba30 remove execute permission from many files that should not have it 2015-11-10 09:48:56 -05:00
Ansariel f4bfb1aadf Merge LL V3.7.9 (AIS3 + SSA) 2014-10-22 02:02:08 +02:00
Stinson Linden 08e83a341e MAINT-4009: Final pass refactoring to eliminate memory allocation related to error reporting that is not properly cleaned up. 2014-05-17 00:41:36 +01:00
Stinson Linden 34b2f2d1f8 MAINT-4009: First pass refactoring to eliminate memory related to error reporting that is not properly cleaned up. 2014-05-16 22:44:25 +01:00
Tank_Master 6babf8abd2 Merge LL 3.7.7 2014-06-09 11:29:57 -07:00
Richard Linden 04bdc8ba83 SH-4294 FIX Interesting: Statistics Texture cache hit rate is always 0%
also, removed LLTrace::init and cleanup
removed derived class implementation of memory stat for LLMemTrackable
is automatic now
2013-07-01 17:04:01 -07:00
Richard Linden 0a96b47663 merge with viewer-release 2013-06-05 19:05:43 -07:00
Graham Madarasz bf6182daa8 Update Mac and Windows breakpad builds to latest 2013-03-29 07:50:08 -07:00
Tank_Master d4640277d0 Merge LL 3.5.3 release. 2013-07-09 16:24:58 -07:00