摘要:
An information handling system includes a memory, a processor, and an instruction tracking unit. The processor executes program code and, while the program code executes, the instruction tracking unit decodes a multi-purpose no-op instruction within the program code. In turn, the instruction tracking unit sends an interrupt to the processor, which invokes a profiling module to collect and store profiling data in a profiling buffer.
摘要:
A method and data processing system for managing running of instructions in a program. A processor of the data processing system receives a monitoring instruction of a monitoring unit. The processor determines if at least one secondary thread of a set of secondary threads is available for use as an assist thread. The processor selects the at least one secondary thread from the set of secondary threads to become the assist thread in response to a determination that the at least one secondary thread of the set of secondary threads is available for use as an assist thread. The processor changes profiling of running of instructions in the program from the main thread to the assist thread.
摘要:
A reference to data in program code is resolved during execution of the program code. A request to resolve the reference is classified based on a state of the referenced data and a source of the request. A transitional resolution for the reference is provided if the referenced data state indicates no accessible definition and resolution of the reference is allowed according to the request classification. A full resolution for the reference is provided if the referenced data state indicates an accessible definition according to the request classification. The request is removed only if the reference resolution is a full resolution.
摘要:
A method and apparatus to guarantee type safety in multithreaded programs, and to guarantee initialization safety in well-behaved multithreaded programs. A plurality of bytecodes representing a program are received and examined to identify bytecodes defining object creation operations and object initialization operations. Upon execution of the plurality of bytecodes, memory barrier operations are performed subsequent to the performance of both the object creation operations and the object initialization operations. This guarantees type safety, and further guarantees initialization safety if the program is well-behaved. Optimization algorithms may also be applied in the compilation of bytecodes to improve performance.
摘要:
A method and apparatus to guarantee type safety in multithreaded programs, and to guarantee initialization safety in well-behaved multithreaded programs. A plurality of bytecodes representing a program are received and examined to identify bytecodes defining object creation operations and object initialization operations. Upon execution of the plurality of bytecodes, memory barrier operations are performed subsequent to the performance of both the object creation operations and the object initialization operations. This guarantees type safety, and further guarantees initialization safety if the program is well-behaved. Optimization algorithms may also be applied in the compilation of bytecodes to improve performance.
摘要:
A method, system and computer program product for generating a read-only lock implementation from a read-only lock portion of program code. In response to determining that a lock portion of the program code is a read-only lock, a read-only lock implementation is generated to protect at least one piece of shared data. The read-only lock implementation comprises a plurality of instructions with dependencies created between the instructions to ensure that a lock corresponding to the data is determined to be free before permitting access to that data. In one embodiment, when executed, the read-only lock implementation loads a lock word from a memory address into a register and places a reserve on the memory address. The lock word is evaluated to determine if the lock is free, and, in response to determining that the lock is tree, at least one piece of shared data protected by the lock is accessed. A value is conditionally stored back to the memory address if the reserve is present. A dependency exists between the step of loading of the lock word and the step of accessing the at least one piece of shared data, thereby causing the step of loading of the lock word to be performed before the step of accessing of the at least one piece of shared data.