In the functions that implement the macros, check if debug is enabled
up-front before the call to the lower debug print function. This
provides a small performance improvement.
Move check for "debug enable" to before the actual call to the debug
print routine. Improves time of ASLTS by about 15%.
Also, remove "safe" exit macros since no complex expressions are
ever used in the return statements.
This change tracks an errata to the ACPI 5.0 document. The AML grammar
will not allow the interpreter to differentiate between a method and a
method invocation when these are used as an argument to the ObjectType
operator.
The ACPI specification change is to disallow a method invocation
(UserTerm) for the ObjectType operator.
This fixes a problem with WaitSemaphore where the timeout always
expires immediately if the semaphore is not available.
The default code uses sem_timedwait to support semaphore timeouts. However, the
full implementation is incorrect. sem_timedwait uses an absolute time value,
not a relative time value. Therefore, clock_gettime must be called first in
order to get the current time. The timeout value must be added to the current
time in order to get the absolute time -- which then becomes the latest we are
willing to wait for the semaphore.
Currently, the incorrect implementation will always timeout immediately. This
is not a huge problem, since this OSL is only used for the user-space ACPICA
utilities, but the ASLTS test suite does depend on the correct behavior for
approximately 20 tests.
ACPICA BZ 990.
1) Check for I/O error after every fopen/fread/fwrite
2) Ensure proper order of size/count params for fread/fwrite
3) Use test of Actual != Requested after all fwrite, most fread
4) Standardize I/O error messages
Improve reliability and maintainability of the code.
Bob Moore, Lv Zheng.
Improve the implementation of the macros.
Change the SETx macros to the style of (destination, source).
Also add ACPI_CASTx companion macros.
Lv Zheng.
During generation of external statements, prevent similar pathnames
that are actually duplicates, such as these:
External (\ABCD)
External (ABCD)
Remove all leading '\' characters from pathnames during the external
statement generation so that duplicates will be detected and tossed.
Improves readability and maintainability of the code.
Fixes a problem with the UART serial bus descriptor for the
number of data bits flags (was incorrectly 2 bits, should be 3).
This command was downreved and did not properly disassemble control
methods with any reasonable complexity. This fix brings the
command up to the same level as the rest of the disassembler.
Adds one new file, dmdeferred.c, which is existing code that is
now common with the main disassembler and the debugger disassembl
command.
Fixes a problem where an incorrect pathname could be generated
for an external declaration if the original reference to the object
includes leading carats.
Tracing is no longer needed for many of the low-level function.
Removing the trace mechanism from these functions improves
performance a small amount, also simplifies the debug trace
output.
Newer versions of Bison emit this prototype, so move the prototype
out of the iASL header to where it is actually used in order
to avoid a duplicate declaration.
This change greatly increases the performance of package objects
within the interpreter. It changes the processing of reference
counts for packages by optimizing for the most common case where
the package subobjects are either integers, strings, or buffers.
Increases the performance of the ASLTS test suite by 1.5X.
Chao Guan. ACPICA BZ 943.