From bbd077bda8118c534d58cbcdc697875147cf09b7 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Fri, 9 Jun 2023 17:58:00 -0700 Subject: SL-18837 set build id based on github workflow run id --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d0f1b59ae6..71b2a62618 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -92,7 +92,7 @@ jobs: echo "Python location: $PYTHON" fi - autobuild configure -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" + autobuild configure --id "${{ github.run_id }}" -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" autobuild build --no-configure # Find artifacts -- cgit v1.2.3 From ee453bc2d9df82dabf425ad61363dacf91338a48 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Thu, 22 Jun 2023 18:27:30 -0700 Subject: SL-18837 fixes for test failures. VERSION_BUILD is now too big to fit in 32 bits, and cpuid doesn't do what we expect under rosetta --- .github/workflows/build.yaml | 3 ++- indra/llcommon/llprocessor.cpp | 2 +- indra/newview/llappviewer.cpp | 4 ++-- indra/newview/llversioninfo.cpp | 2 +- indra/newview/llversioninfo.h | 2 +- indra/newview/llweb.cpp | 2 +- 6 files changed, 8 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 71b2a62618..00dd7ed116 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -31,6 +31,7 @@ jobs: AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables AUTOBUILD_VSVER: "170" + AUTOBUILD_BUILD_ID: ${{ github.run_id }} DEVELOPER_DIR: ${{ matrix.developer_dir }} # Ensure that viewer builds engage Bugsplat. BUGSPLAT_DB: "SecondLife_Viewer_2018" @@ -93,7 +94,7 @@ jobs: fi autobuild configure --id "${{ github.run_id }}" -- -DVIEWER_CHANNEL="Second Life Test ${GIT_REF##*/}" - autobuild build --no-configure + autobuild build --no-configure # Find artifacts if [[ "$RUNNER_OS" == "Windows" ]]; then diff --git a/indra/llcommon/llprocessor.cpp b/indra/llcommon/llprocessor.cpp index 4a1a81f083..28f8bc2b93 100644 --- a/indra/llcommon/llprocessor.cpp +++ b/indra/llcommon/llprocessor.cpp @@ -746,7 +746,7 @@ private: __cpuid(0x1, eax, ebx, ecx, edx); if(feature_infos[0] != (S32)edx) { - LL_ERRS() << "machdep.cpu.feature_bits doesn't match expected cpuid result!" << LL_ENDL; + LL_WARNS() << "machdep.cpu.feature_bits doesn't match expected cpuid result!" << LL_ENDL; } #endif // LL_RELEASE_FOR_DOWNLOAD diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 8235e4466c..47cde3755b 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -3552,7 +3552,7 @@ void LLAppViewer::writeSystemInfo() gDebugInfo["ClientInfo"]["MajorVersion"] = LLVersionInfo::instance().getMajor(); gDebugInfo["ClientInfo"]["MinorVersion"] = LLVersionInfo::instance().getMinor(); gDebugInfo["ClientInfo"]["PatchVersion"] = LLVersionInfo::instance().getPatch(); - gDebugInfo["ClientInfo"]["BuildVersion"] = LLVersionInfo::instance().getBuild(); + gDebugInfo["ClientInfo"]["BuildVersion"] = STRINGIZE(LLVersionInfo::instance().getBuild()); gDebugInfo["ClientInfo"]["AddressSize"] = LLVersionInfo::instance().getAddressSize(); gDebugInfo["CAFilename"] = gDirUtilp->getCAFile(); @@ -5669,7 +5669,7 @@ void LLAppViewer::handleLoginComplete() gDebugInfo["ClientInfo"]["MajorVersion"] = LLVersionInfo::instance().getMajor(); gDebugInfo["ClientInfo"]["MinorVersion"] = LLVersionInfo::instance().getMinor(); gDebugInfo["ClientInfo"]["PatchVersion"] = LLVersionInfo::instance().getPatch(); - gDebugInfo["ClientInfo"]["BuildVersion"] = LLVersionInfo::instance().getBuild(); + gDebugInfo["ClientInfo"]["BuildVersion"] = STRINGIZE(LLVersionInfo::instance().getBuild()); LLParcel* parcel = LLViewerParcelMgr::getInstance()->getAgentParcel(); if ( parcel && parcel->getMusicURL()[0]) diff --git a/indra/newview/llversioninfo.cpp b/indra/newview/llversioninfo.cpp index 376a7fce76..62bfa24e29 100644 --- a/indra/newview/llversioninfo.cpp +++ b/indra/newview/llversioninfo.cpp @@ -91,7 +91,7 @@ S32 LLVersionInfo::getPatch() return LL_VIEWER_VERSION_PATCH; } -S32 LLVersionInfo::getBuild() +S64 LLVersionInfo::getBuild() { return LL_VIEWER_VERSION_BUILD; } diff --git a/indra/newview/llversioninfo.h b/indra/newview/llversioninfo.h index 02ff0c094a..122bd5c47a 100644 --- a/indra/newview/llversioninfo.h +++ b/indra/newview/llversioninfo.h @@ -61,7 +61,7 @@ public: S32 getPatch(); /// return the build number as an integer - S32 getBuild(); + S64 getBuild(); /// return the full viewer version as a string like "2.0.0.200030" std::string getVersion(); diff --git a/indra/newview/llweb.cpp b/indra/newview/llweb.cpp index c4d873dd22..df8e9770f3 100644 --- a/indra/newview/llweb.cpp +++ b/indra/newview/llweb.cpp @@ -160,7 +160,7 @@ std::string LLWeb::expandURLSubstitutions(const std::string &url, substitution["VERSION_MAJOR"] = LLVersionInfo::instance().getMajor(); substitution["VERSION_MINOR"] = LLVersionInfo::instance().getMinor(); substitution["VERSION_PATCH"] = LLVersionInfo::instance().getPatch(); - substitution["VERSION_BUILD"] = LLVersionInfo::instance().getBuild(); + substitution["VERSION_BUILD"] = STRINGIZE(LLVersionInfo::instance().getBuild()); substitution["CHANNEL"] = LLVersionInfo::instance().getChannel(); substitution["GRID"] = LLGridManager::getInstance()->getGridId(); substitution["GRID_LOWERCASE"] = utf8str_tolower(LLGridManager::getInstance()->getGridId()); -- cgit v1.2.3 From a163931b773eb9c863b804eb4af1e63e398e6360 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Mon, 26 Jun 2023 17:06:37 -0700 Subject: SL-18837 improvements suggested by code review --- indra/newview/llappviewer.cpp | 4 ++-- indra/newview/llweb.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 47cde3755b..99ace834c2 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -3552,7 +3552,7 @@ void LLAppViewer::writeSystemInfo() gDebugInfo["ClientInfo"]["MajorVersion"] = LLVersionInfo::instance().getMajor(); gDebugInfo["ClientInfo"]["MinorVersion"] = LLVersionInfo::instance().getMinor(); gDebugInfo["ClientInfo"]["PatchVersion"] = LLVersionInfo::instance().getPatch(); - gDebugInfo["ClientInfo"]["BuildVersion"] = STRINGIZE(LLVersionInfo::instance().getBuild()); + gDebugInfo["ClientInfo"]["BuildVersion"] = std::to_string(LLVersionInfo::instance().getBuild()); gDebugInfo["ClientInfo"]["AddressSize"] = LLVersionInfo::instance().getAddressSize(); gDebugInfo["CAFilename"] = gDirUtilp->getCAFile(); @@ -5669,7 +5669,7 @@ void LLAppViewer::handleLoginComplete() gDebugInfo["ClientInfo"]["MajorVersion"] = LLVersionInfo::instance().getMajor(); gDebugInfo["ClientInfo"]["MinorVersion"] = LLVersionInfo::instance().getMinor(); gDebugInfo["ClientInfo"]["PatchVersion"] = LLVersionInfo::instance().getPatch(); - gDebugInfo["ClientInfo"]["BuildVersion"] = STRINGIZE(LLVersionInfo::instance().getBuild()); + gDebugInfo["ClientInfo"]["BuildVersion"] = std::to_string(LLVersionInfo::instance().getBuild()); LLParcel* parcel = LLViewerParcelMgr::getInstance()->getAgentParcel(); if ( parcel && parcel->getMusicURL()[0]) diff --git a/indra/newview/llweb.cpp b/indra/newview/llweb.cpp index df8e9770f3..9afe332025 100644 --- a/indra/newview/llweb.cpp +++ b/indra/newview/llweb.cpp @@ -160,7 +160,7 @@ std::string LLWeb::expandURLSubstitutions(const std::string &url, substitution["VERSION_MAJOR"] = LLVersionInfo::instance().getMajor(); substitution["VERSION_MINOR"] = LLVersionInfo::instance().getMinor(); substitution["VERSION_PATCH"] = LLVersionInfo::instance().getPatch(); - substitution["VERSION_BUILD"] = STRINGIZE(LLVersionInfo::instance().getBuild()); + substitution["VERSION_BUILD"] = std::to_string(LLVersionInfo::instance().getBuild()); substitution["CHANNEL"] = LLVersionInfo::instance().getChannel(); substitution["GRID"] = LLGridManager::getInstance()->getGridId(); substitution["GRID_LOWERCASE"] = utf8str_tolower(LLGridManager::getInstance()->getGridId()); -- cgit v1.2.3 From 0998d46f47927badbd3f7d3a4b7a83a11896a5c9 Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Fri, 14 Jul 2023 18:04:14 -0700 Subject: Fix "intermittent" llrand unit test failure on windows on DRTVWR-578. we must return less than 1.0 when rand() returns RAND_MAX also, disable 32 bit build now that we have deprecated it. https://community.secondlife.com/blogs/entry/13464-end-of-support-for-second-life-32-bit-windows-viewer-and-updated-minimum-system-requirements-for-macos-to-1013/ --- .github/workflows/build.yaml | 8 ++------ indra/llcommon/llrand.cpp | 4 ++-- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 00dd7ed116..3e0330d77b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -13,18 +13,14 @@ jobs: matrix: runner: [windows-large, macos-12-xl] configuration: [Release] - addrsize: [64] python-version: ["3.11"] include: - - runner: windows-large - configuration: Release - addrsize: 32 - python-version: "3.11" - runner: macos-12-xl developer_dir: "/Applications/Xcode_14.0.1.app/Contents/Developer" + python-version: "3.11" runs-on: ${{ matrix.runner }} env: - AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }} + AUTOBUILD_ADDRSIZE: 64 AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }} # authorizes fetching private constituent packages AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} diff --git a/indra/llcommon/llrand.cpp b/indra/llcommon/llrand.cpp index cb28a8f5c3..1b6963a9dd 100644 --- a/indra/llcommon/llrand.cpp +++ b/indra/llcommon/llrand.cpp @@ -82,7 +82,7 @@ static LLSeedRand sRandomSeeder; inline F64 ll_internal_random_double() { #if LL_WINDOWS - return (F64)rand() / (F64)RAND_MAX; + return (F64)rand() / (F64)(RAND_MAX+1); #else return drand48(); #endif @@ -90,7 +90,7 @@ inline F64 ll_internal_random_double() inline F32 ll_internal_random_float() { #if LL_WINDOWS - return (F32)rand() / (F32)RAND_MAX; + return (F32)rand() / (F32)(RAND_MAX+1); #else return (F32)drand48(); #endif -- cgit v1.2.3