- Dec 19, 2012
-
-
GetExtendedProcessorName() may sometimes return "Unknown family" when we could return something more meaningful. Some systems (e.g. PA-RISC on Linux) export a "cpu" value in /proc/cpuinfo that has a beautified processor name in it (e.g. "PA8600 (PCX-W+)"). If we have not found something nice but this field is present use that information. Change-Id: I72561bdcba12f3f43d86f96bf3ebfae36ea22421
-
Change-Id: I729237c700e58eca9ea4fdc563f00208cfc81cff
-
If the given key (e.g. "cpu") is matched at the beginning of any line the value was returned regardless if that line would be the correct match (e.g. "cpu family" is not the correct line). Make sure between the key and the colon are only spaces and tabs. Change-Id: I8955add3635a0afb73a9f07f7a0bcf600b7c7015
-
Non-x86 architectures (namely PA-RISC) may not have the "cache size" line, but others. Search for all and sum up their results. Change-Id: Ie8e1c52e2b8be69b0b919bb029c1db95c04a9309
-
Change-Id: Ib753ad6171b0f83f6ad505a904c7d3124d734ee1
-
- Dec 14, 2012
-
-
Brad King authored
The Registry class is not used by any other part of KWSys or by any of the major dependent projects (CMake, ITK, VTK, ParaView, etc.). Remove it from KWSys proper. It can be kept in a specific dependent if necessary. Change-Id: I82c0ae2f6a354e9fc5b267faf8fbbeaf9e99a75e
-
- Nov 29, 2012
-
-
Sean McBride authored
Change-Id: Iaa1cd4ff7ae9a2b4efab0094544af0789c376c0a
-
Some compilers, notably Clang, will warn at compile time (or runtime with debug flags) if they detect a null dereference. Try to outsmart them by dereferencing an address a little larger than NULL. Change-Id: I53c6512f814ad3e8977c076904f0415e8aaaaea5
-
- Nov 14, 2012
-
-
Brad King authored
We no longer support Windows 98. Remove Win9x-specific code and supporting infrastructure. This simplifies the implementation in several places. Change-Id: Ic3062a81e5880b649feeedf397bf846400f12526
-
- Nov 08, 2012
-
-
Brad King authored
From "man getifaddrs": "This means ifa_addr and other fields can actually be NULL if the interface has no address..." Reported-by:
Kornel Benko <kornel@lyx.org> Change-Id: I9d9ad3ae9fb50cbcab46fa8c06b270e4c56c288e
-
- Nov 05, 2012
-
-
Brad King authored
In order to compute FQDN portably in the future we will need an incremental series of try_compile tests to build up the list of available headers and supported APIs. For now implement it only on platforms where we have already hard-coded preprocessor tests for the headers. Change-Id: Ie1b2ad30ef3c2d5939071c7cbd32826be64d7e29
-
Brad King authored
Commit 857bda17 (SystemInformation: Report more information, 2012-05-29) attempted to refactor the internal CallSwVers helper to avoid duplicate code but introduced a regression in output parsing. Run sw_vers using our RunProcess helper rather than popen and restore the original output processing approach. Change-Id: I550af5813dcad5beaec86c7c5fa1f00bcc9070b6
-
Brad King authored
The backtrace API was added in LSB 4.1 but does not exist in 4.0. Change-Id: Iae84de74d83135c53f4c5fd7bd16d9764d3c161b
-
- Nov 02, 2012
-
-
Brad King authored
Replace accidental use of kwsys_stl:: with kwsys_ios:: to reference string streams. The former is the namespace for STL, the latter for streams. Change-Id: I8c18a49c34633a4a3760d6f31192ff82ce4ce537
-
- Oct 16, 2012
-
-
Brad King authored
The LoadLines filename overload is used only on Linux. Change-Id: I71b18c36aa033471aeeecba4cc002f293577cb8a
-
- Oct 12, 2012
-
-
Brad King authored
Drop unused helper GetFieldFromCommand. Define helpers LoadLines NameValue GetFieldFromFile GetFieldsFromFile GetFieldsFromCommand StacktraceSignalHandler only on platforms where they are used. Hide all helpers in an anonymous namespace so they are not visible outside the SystemInformation translation unit. Change-Id: I514881a8f253d72e90a0fb8bf1a6d7d9bc7e01c5
-
Brad King authored
Switch order of helper function definitions to avoid referencing names before they are declared. Change-Id: I25243b2042163f920f056b71941c88e6cfabac16
-
- Oct 10, 2012
-
-
Brad King authored
-
- Oct 09, 2012
-
-
Burlen Loring authored
Add methods to report host memory total, host memory available, process memory available, host memory used, and process memory used. In this context memory is unavailable if there are resource limits in place that would prevent its use. Such resource limits assumed to be applied on a per host basis both to cooperatively operating process groups, such as mpi programms running in parallel, and to individual processes. When reporting host memory available consult an application specified environment variable. When reporting process memory available consult unix resource rlimits and an application specified environment variable. The environmant variables provide a means of communicating resource limits that are being applied in a non-standard way. Change-Id: Ifb3b0fdaab8db0ab87140fa2dcafad3c51e2d874
-
- Oct 06, 2012
-
-
sysctlbyname() can mutate the length param you give it, so you need to reset it before every call. Change-Id: I86ba705ec78c02b1d5efeb4609cb828ea4c490fc
-
Change-Id: Ic1dcd37dabbf34ce721b81c6a787dafe758105a4
- Oct 01, 2012
- Sep 29, 2012
-
-
Brad King authored
Cast StacktraceSignalHandler to extern "C" to avoid the warning: SystemInformation.cxx, line 3048: Warning (Anachronism): Assigning void(*)(int,siginfo*,void*) to extern "C" void(*)(int,siginfo*,void*) on the Sun compiler. Change-Id: I8f8ac99656bc8ee6f604ea69c415a093699ca86d
-
Brad King authored
Fix interaction between local variables and conditional code in methods SystemInformationImplementation::GetFullyQualifiedDomainName SystemInformationImplementation::GetMemoryTotal SystemInformationImplementation::GetMemoryUsed SystemInformationImplementation::GetProcessId to avoid assigning values to local variables that are never used. While at it, fix GetMemoryUsed() to not leak the OpenProcess handle when GetProcessMemoryInfo fails. Change-Id: I582b70c7b4795df6b97bdeafc6328001dc5ce3ee
-
Brad King authored
Change-Id: I8788a5c8d8a8e9116675b1692b9ce102a943fc13
-
Brad King authored
Change-Id: Ib700bc38f9bc18ae2bb899b9c84c9cec91f9cfdb
-
Brad King authored
Change-Id: Ia10c74f423e0c7264ef989135aabf2f2b6f64911
-
Brad King authored
Use either GlobalMemoryStatus or GlobalMemoryStatusEx on any Windows compiler. Use Psapi only where it is available. Change-Id: I66ab965906ab0151eb52ed4fc345b29c466b556a
-
- Sep 27, 2012
-
-
Brad King authored
Change-Id: I52102945c67c902bc8578363b0d4712081a7fa1f
-
Brad King authored
Move general UNIX includes out of __linux and __APPLE__ blocks to anywhere _WIN32 is not defined. Fix preprocessing rules to implement GetFullyQualifiedDomainName only where it is known to work. Change-Id: I2147d38359af169069fa1a9d516614a92902563c
-
Support probing of the current process memory usage in KB (linux,win,mac), the total physical memory in KB (linux,win,mac), and the model name field of the cpuinfo (Linux only). Add a method to return the host's FQDN (non-AIX), and methods to test for OS type (Windows, Apple, Linux). Change-Id: Iedb238f4ca49d5f13385a71a592ec67cec73b29c
-
Brad King authored
Configure GitSetup scripts for KWSys. Run them from a single SetupForDevelopment.sh script. Change-Id: Ic4f02175fd65e2f4fe5688e43313766c2b23458f
-
Brad King authored
Add GitSetup/ directory using subtree merge from the general GitSetup repository "setup" branch. Change-Id: Ibbdf355c1c28eada01d02a785533d0d82c25205a
-
Brad King authored
Add a script implementing our standard "git gerrit-push" alias. When invoked, first check that the current branch is a named topic. Then fetch 'master' from the 'gerrit' remote repository so the local repository can compute a minimal pack to push. Finally, push the topic to the 'gerrit' remote as "refs/for/master/$topic".
-
- Sep 19, 2012
-
-
Brad King authored
-
- Sep 18, 2012
-
-
Change-Id: Ia49de4dfa022f9f284733e8b42c22c987b145bde
-
Brad King authored
Commit "KWSys: Fix SystemTools environment memory handling" (2012-04-26) added a _WIN32 case inside !KWSYS_CXX_HAS_ENVIRON_IN_STDLIB_H to dllimport the "environ" global. Howver, KWSYS_CXX_HAS_ENVIRON_IN_STDLIB_H is true on every Windows toolchain we support so the case is never reached. Furthermore, even if it were reached the use of dllimport is incorrect because the toolchain might not be compiling with a dynamic runtime library. Remove the unused incorrect line and supporting conditionals. Change-Id: If2b24fcbec18a711e4fbc28c5d027506d14f9ccb
-
- Sep 17, 2012
-
-
Brad King authored
Define macros _CRT_NONSTDC_NO_DEPRECATE _CRT_SECURE_NO_DEPRECATE _CRT_SECURE_NO_WARNINGS _SCL_SECURE_NO_DEPRECATE for all translation units in KWSys. Drop definitions from Configure.h that are now redundant. Change-Id: I326a1edb6c5a8ab977ecd2370eed6fcdf4775208
-