File tree Expand file tree Collapse file tree 1 file changed +44
-0
lines changed
Expand file tree Collapse file tree 1 file changed +44
-0
lines changed Original file line number Diff line number Diff line change 1+ #ifndef Py_CORE_UOP_H
2+ #define Py_CORE_UOP_H
3+ #ifdef __cplusplus
4+ extern "C" {
5+ #endif
6+
7+ #ifndef Py_BUILD_CORE
8+ # error "this header requires Py_BUILD_CORE define"
9+ #endif
10+
11+ #include <stdint.h>
12+ /* Depending on the format,
13+ * the 32 bits between the oparg and operand are:
14+ * UOP_FORMAT_TARGET:
15+ * uint32_t target;
16+ * UOP_FORMAT_JUMP
17+ * uint16_t jump_target;
18+ * uint16_t error_target;
19+ */
20+ typedef struct _PyUOpInstruction {
21+ uint16_t opcode :15 ;
22+ uint16_t format :1 ;
23+ uint16_t oparg ;
24+ union {
25+ uint32_t target ;
26+ struct {
27+ uint16_t jump_target ;
28+ uint16_t error_target ;
29+ };
30+ };
31+ uint64_t operand0 ; // A cache entry
32+ uint64_t operand1 ;
33+ #ifdef Py_STATS
34+ uint64_t execution_count ;
35+ #endif
36+ } _PyUOpInstruction ;
37+
38+ // This is the length of the trace we project initially.
39+ #define UOP_MAX_TRACE_LENGTH 1200
40+
41+ #ifdef __cplusplus
42+ }
43+ #endif
44+ #endif /* !Py_INTERNAL_UOP_H */
You can’t perform that action at this time.
0 commit comments