llvm-project/flang/unittests
Diana Picus 9df0ba599c [flang] Implement GET_ENVIRONMENT_VARIABLE(VALUE)
Implement the second entry point for GET_ENVIRONMENT_VARIABLE. Reuse
existing bits and pieces wherever possible.

This patch also increases CFI_* error codes in order to avoid conflicts.
GET_ENVIRONMENT_VARIABLE is required to return a status of 1 if an
environment variable does not exist and 2 if environment variables are
not supported. However, if we add status codes for that they will
conflict with CFI_ERROR_BASE_ADDR_NULL and CFI_ERROR_BASE_ADDR_NOT_NULL,
which are also 1 and 2 at the moment. We therefore move all CFI error
codes up (an arbitrary) 10 spots to make room. Hopefully this isn't
a problem, since we weren't matching the CFI error codes that gfortran
uses anyway. It may still be an issue if any other runtime functions
will need to return a status of 1 or 2, but we should probably deal with
that when/if it occurs.

Differential Revision: https://reviews.llvm.org/D112698
2021-11-01 09:19:20 +00:00
..
Decimal [flang] Make flang build compatible with LLVM dylib 2020-10-14 14:27:25 +02:00
Evaluate [flang] Remove incorrect unit test 2021-10-04 18:27:14 -07:00
Frontend [flang][nfc] Fix variable names in `FrontendOptions` & `PreprocessorOptions` 2021-08-02 10:08:31 +00:00
Optimizer [fir] Add utility function to FIRBuilder and MutableBox 2021-10-22 10:00:34 +02:00
Runtime [flang] Implement GET_ENVIRONMENT_VARIABLE(VALUE) 2021-11-01 09:19:20 +00:00
CMakeLists.txt [fir] Split FIROptimizer lib into several smaller libraries 2021-10-05 14:02:32 +02:00