ROSE 0.11.145.247
SgAsmNERelocEntry.h
1
2#ifndef ROSE_SgAsmNERelocEntry_H
3#define ROSE_SgAsmNERelocEntry_H
4#include <RoseFirst.h>
5#include <Cxx_GrammarDeclarations.h>
6#include <SgAsmExecutableFileFormat.h>
7
8
9
10/* #line 1 "/workspace/src/ROSETTA/Grammar/grammarClassDeclarationMacros.macro" */
11
12// WARNING -- GENERATED CODE -- DO NOT MODIFY THIS CODE -- WARNING!
13// This code is automatically generated for each
14// terminal and non-terminal within the defined
15// grammar. There is a simple way to change the
16// code to fix bugs etc. See the ROSE README file
17// for directions.
18
19// tps: (02/22/2010): Adding DLL export requirements
20#include "rosedll.h"
21
22// predeclarations for SgAsmNERelocEntry
23
24/* #line 25 "../../../src/frontend/SageIII//SgAsmNERelocEntry.h" */
25/* #line 6072 "/workspace/src/ROSETTA/src/binaryInstruction.C" */
26
27#include <Rose/BinaryAnalysis/Address.h>
28
29
30/* #line 13 "/workspace/src/ROSETTA/Grammar/grammarClassDeclarationMacros.macro after subst for $PREDECLARATIONS" */
31
32/* #line 14 "/workspace/src/ROSETTA/Grammar/grammarClassDeclarationMacros.macro" */
33
34#if !defined(DOCUMENTATION)
35// Class Definition for SgAsmNERelocEntry
36class ROSE_DLL_API SgAsmNERelocEntry : public SgAsmExecutableFileFormat
37 {
38 public:
39
40
41/* #line 42 "../../../src/frontend/SageIII//SgAsmNERelocEntry.h" */
42
43 virtual SgNode* copy ( SgCopyHelp& help) const override;
44// Start of memberFunctionString
45/* #line 6135 "/workspace/src/ROSETTA/src/binaryInstruction.C" */
46
47
48 //----------------------- Boost serialization for SgAsmNERelocEntry -----------------------
49#ifdef ROSE_ENABLE_BOOST_SERIALIZATION
50private:
51 friend class boost::serialization::access;
52
53 template<class S>
54 void serialize(S &s, const unsigned /*version*/) {
55 debugSerializationBegin("SgAsmNERelocEntry");
56 s & BOOST_SERIALIZATION_BASE_OBJECT_NVP(SgAsmExecutableFileFormat);
57 s & BOOST_SERIALIZATION_NVP(p_src_type);
58 s & BOOST_SERIALIZATION_NVP(p_modifier);
59 s & BOOST_SERIALIZATION_NVP(p_tgt_type);
60 s & BOOST_SERIALIZATION_NVP(p_flags);
61 s & BOOST_SERIALIZATION_NVP(p_src_offset);
62 s & BOOST_SERIALIZATION_NVP(p_iref);
63 s & BOOST_SERIALIZATION_NVP(p_iord);
64 s & BOOST_SERIALIZATION_NVP(p_iname);
65 s & BOOST_SERIALIZATION_NVP(p_osfixup);
66 debugSerializationEnd("SgAsmNERelocEntry");
67 }
68#endif // ROSE_ENABLE_BOOST_SERIALIZATION
70 // Local types
72public:
73 /* NERelocEntry_disk -- variable size with multiple levels of 'union'. It's easier to just parse it in NERelocEntry::ctor()
74 * than defining it here as a struct. */
75 enum NERelocSrcType {
76 RF_SRCTYPE_8OFF = 0, /* Byte offset */
77 RF_SRCTYPE_WORDSEG = 2, /* Word segment, 16-bit selector */
78 RF_SRCTYPE_16PTR = 3, /* 16-bit far pointer */
79 RF_SRCTYPE_16OFF = 5, /* 16-bit offset */
80 RF_SRCTYPE_32PTR = 6, /* 32-bit far pointer */
81 RF_SRCTYPE_32OFF = 7, /* 32-bit offset */
82 RF_SRCTYPE_NEARCALL = 8, /* near call or jump, WORD/DWROD based on section attribute */
83 RF_SRCTYPE_48PTR = 11, /* 48-bit pointer */
84 RF_SRCTYPE_32OFF_b = 13 /* 32-bit offset (not sure how this differs from case 7) */
85 };
86
87 enum NERelocTgtType {
88 RF_TGTTYPE_IREF = 0, /* Internal reference */
89 RF_TGTTYPE_IORD = 1, /* Imported (extern) ordinal */
90 RF_TGTTYPE_INAME = 2, /* Imported (extern) name */
91 RF_TGTTYPE_OSFIXUP = 3 /* Operating system fixup */
92 };
93
94 enum NERelocModifiers {
95 RF_MODIFIER_SINGLE = 1,
96 RF_MODIFIER_MULTI = 3
97 };
98
99 enum NERelocFlags {
100 RF_ADDITIVE = 0x01, /* add target to source rather than replace source with target */
101 RF_RESERVED = 0x02, /* reserved bits */
102 RF_2EXTRA = 0x04, /* relocation info has size with new two bytes at end */
103 RF_32ADD = 0x08, /* addition with 32-bits rather than 16 */
104 RF_16SECTION = 0x10, /* 16-bit object number & module name rather than 8-bit */
105 RF_8ORDINAL = 0x20 /* Ordinal is 8-bits rather than 16 */
106 };
107
108 // DQ (8/7/2008): At only (I hope) the risk of using more memory that required, break the union so that we can better support
109 // this in ROSETTA. One solution might be to implement a common base class of unsigned, unsigned, Rose::BinaryAnalysis::Address;
110 // and then use member functions to access the data in the base class.
111 struct iref_type { /*tgt_type==0x00: internal reference*/
112 unsigned sect_idx; /* section index (1-origin) */
113 unsigned res1; /* reserved */
115
116#ifdef ROSE_ENABLE_BOOST_SERIALIZATION
117 template<class S>
118 void serialize(S &s, const unsigned /*version*/) {
119 s & BOOST_SERIALIZATION_NVP(sect_idx);
120 s & BOOST_SERIALIZATION_NVP(res1);
121 s & BOOST_SERIALIZATION_NVP(tgt_offset);
122 }
123#endif
124
125 // Added to support RTI support in ROSE
126 friend std::ostream & operator<< ( std::ostream & os, const iref_type & x );
127
128 iref_type();
129 };
130
131 struct iord_type { /*tgt_type==0x01: imported ordinal*/
132 unsigned modref; /* 1-based index into import module table */
133 unsigned ordinal;
134 Rose::BinaryAnalysis::Address addend; /* value to add (only present for flags & RF_2EXTRA) */
135
136#ifdef ROSE_ENABLE_BOOST_SERIALIZATION
137 template<class S>
138 void serialize(S &s, const unsigned /*version*/) {
139 s & BOOST_SERIALIZATION_NVP(modref);
140 s & BOOST_SERIALIZATION_NVP(ordinal);
141 s & BOOST_SERIALIZATION_NVP(addend);
142 }
143#endif
144
145 // Added to support RTI support in ROSE
146 friend std::ostream & operator<< ( std::ostream & os, const iord_type & x );
147
148 iord_type();
149 };
150
151 struct iname_type { /*tgt_type==0x02: imported name*/
152 unsigned modref; /* 1-based index into import module table */
153 unsigned nm_off; /* offset into import procedure names */
154 Rose::BinaryAnalysis::Address addend; /* value to add (only present for flags & RF_2EXTRA) */
155
156#ifdef ROSE_ENABLE_BOOST_SERIALIZATION
157 template<class S>
158 void serialize(S &s, const unsigned /*version*/) {
159 s & BOOST_SERIALIZATION_NVP(modref);
160 s & BOOST_SERIALIZATION_NVP(nm_off);
161 s & BOOST_SERIALIZATION_NVP(addend);
162 }
163#endif
164
165 // Added to support RTI support in ROSE
166 friend std::ostream & operator<< ( std::ostream & os, const iname_type & x );
167
168 iname_type();
169 };
170
171 struct osfixup_type { /*tgt_type==0x03: operating system fixup*/
172 unsigned type;
173 unsigned res3;
174
175#ifdef ROSE_ENABLE_BOOST_SERIALIZATION
176 template<class S>
177 void serialize(S &s, const unsigned /*version*/) {
178 s & BOOST_SERIALIZATION_NVP(type);
179 s & BOOST_SERIALIZATION_NVP(res3);
180 }
181#endif
182
183 // Added to support RTI support in ROSE
184 friend std::ostream & operator<< ( std::ostream & os, const osfixup_type & x );
185
186 osfixup_type();
187 };
188
190 // Properties
192public:
193public:
194 SgAsmNERelocEntry::NERelocSrcType const& get_src_type() const;
195 void set_src_type(SgAsmNERelocEntry::NERelocSrcType const&);
196
197public:
198 SgAsmNERelocEntry::NERelocModifiers const& get_modifier() const;
199 void set_modifier(SgAsmNERelocEntry::NERelocModifiers const&);
200
201public:
202 SgAsmNERelocEntry::NERelocTgtType const& get_tgt_type() const;
203 void set_tgt_type(SgAsmNERelocEntry::NERelocTgtType const&);
204
205public:
206 SgAsmNERelocEntry::NERelocFlags const& get_flags() const;
207 void set_flags(SgAsmNERelocEntry::NERelocFlags const&);
208
209public:
210 Rose::BinaryAnalysis::Address const& get_src_offset() const;
211 void set_src_offset(Rose::BinaryAnalysis::Address const&);
212
213public:
214 SgAsmNERelocEntry::iref_type const& get_iref() const;
215 void set_iref(SgAsmNERelocEntry::iref_type const&);
216
217public:
218 SgAsmNERelocEntry::iord_type const& get_iord() const;
219 void set_iord(SgAsmNERelocEntry::iord_type const&);
220
221public:
222 SgAsmNERelocEntry::iname_type const& get_iname() const;
223 void set_iname(SgAsmNERelocEntry::iname_type const&);
224
225public:
226 SgAsmNERelocEntry::osfixup_type const& get_osfixup() const;
227 void set_osfixup(SgAsmNERelocEntry::osfixup_type const&);
229 // Functions
231public:
234 void dump(FILE*, const char *prefix, ssize_t idx) const;
235public:
237 virtual ~SgAsmNERelocEntry();
238
239public:
242
243protected:
251
252
253// End of memberFunctionString
254// Start of memberFunctionString
255/* #line 1 "/workspace/src/ROSETTA/Grammar/Common.code" */
256
257// *** COMMON CODE SECTION BEGINS HERE ***
258
259 public:
260
261 // DQ (3/25/3006): I put this back in because it had the logic for where the copy function required
262 // and not required which is required to match the other aspects of the copy mechanism code generation.
263 // Specifically it is a problem to declare the copy function everywhere because it is not implemented
264 // for the SgSymbol IR nodes. I'm not clear why it is not implemented for these IR nodes.
265 /* \brief Copies AST (whole subtree, depending on the SgCopyHelp class */
266 // virtual SgNode* copy ( const SgCopyHelp & help) const;
267
269 virtual std::string class_name() const override;
270
272 virtual VariantT variantT() const override; // MS: new variant used in tree traversal
273
275 // King84 (2010.08.16): Moved this to an enum to save space, since it's only used at compiler-time anyway.
276 // static const VariantT static_variant = V_SgAsmNERelocEntry;
277 enum { static_variant = V_SgAsmNERelocEntry };
278
279 /* the generated cast function */
281 ROSE_DLL_API friend SgAsmNERelocEntry* isSgAsmNERelocEntry( SgNode * s );
282
284 ROSE_DLL_API friend const SgAsmNERelocEntry* isSgAsmNERelocEntry( const SgNode * s );
285
286 // ******************************************
287 // * Memory Pool / New / Delete
288 // ******************************************
289
290 public:
292 static const unsigned pool_size; //
294 static std::vector<unsigned char *> pools; //
296 static SgAsmNERelocEntry * next_node; //
297
299 static unsigned long initializeStorageClassArray(SgAsmNERelocEntryStorageClass *); //
300
302 static void clearMemoryPool(); //
303 static void deleteMemoryPool(); //
304
306 static void extendMemoryPoolForFileIO(); //
307
309 static SgAsmNERelocEntry * getPointerFromGlobalIndex(unsigned long); //
311 static SgAsmNERelocEntry * getPointerFromGlobalIndex(AstSpecificDataManagingClass *, unsigned long); //
312
314 static unsigned long getNumberOfValidNodesAndSetGlobalIndexInFreepointer(unsigned long); //
316 static void resetValidFreepointers(); //
318 static unsigned long getNumberOfLastValidPointer(); //
319
320
321#if defined(INLINE_FUNCTIONS)
323 inline void *operator new (size_t size);
324#else
326 void *operator new (size_t size);
327#endif
329 void operator delete (void* pointer, size_t size);
330
331 // DQ (4/5/2007): This is not the correct operator that we want, but appears to be required to compile ROSE with ROSE.
332 void operator delete (void* pointer)
333 {
334 // This is the generated delete operator...
335 SgAsmNERelocEntry::operator delete (pointer,sizeof(SgAsmNERelocEntry));
336 }
337
339 static size_t numberOfNodes();
340
342 static size_t memoryUsage();
343
344 // End of scope which started in IR nodes specific code
345 /* */
346
347 /* name Internal Functions
348 \brief Internal functions ... incomplete-documentation
349
350 These functions have been made public as part of the design, but they are suggested for internal use
351 or by particularly knowledgeable users for specialized tools or applications.
352
353 \internal We could not make these private because they are required by user for special purposes. And
354 it would be unwieldy to have many of the internal classes in ROSE be explicitly defined as friends.
355
356 */
357
358 // MS: 02/12/02 container of pointers to AST successor nodes used in the traversal
359 // overridden in every class by *generated* implementation
361 virtual std::vector<SgNode*> get_traversalSuccessorContainer() const override;
362 // MS: 06/28/02 container of names of variables or container indices
363 // used used in the traversal to access AST successor nodes
364 // overridden in every class by *generated* implementation
367 virtual std::vector<std::string> get_traversalSuccessorNamesContainer() const override;
368
369 // GB (09/25/2007): Functions for index-based access to traversal successors; these are hopefully a lot faster
370 // than all the vector copies. The implementation for these functions is generated for each class.
372 virtual size_t get_numberOfTraversalSuccessors() const override;
374 virtual SgNode *get_traversalSuccessorByIndex(size_t idx) const override;
376 virtual size_t get_childIndex(SgNode *child) const override;
377
378#ifndef ROSE_USE_INTERNAL_FRONTEND_DEVELOPMENT
379 // MS: 08/16/2002 method for generating RTI information
381 virtual RTIReturnType roseRTI() override;
382#endif
383 /* */
384
385
386
387 /* name Deprecated Functions
388 \brief Deprecated functions ... incomplete-documentation
389
390 These functions have been deprecated from use.
391 */
392 /* */
393
395 virtual const char* sage_class_name() const override ROSE_DEPRECATED_FUNCTION;
396
397 // JJW (10/16/2008): Changed to a single function in Node.code, and put
398 // getVariant() in #if 0 block to prevent confusing Doxygen
399#if 0
401 virtual int variant() const ROSE_DEPRECATED_FUNCTION;
403 // virtual int getVariant() const ROSE_DEPRECATED_FUNCTION;
404#endif
405 /* */
406
407
408
409
410 public:
411 /* name Traversal Support Functions
412 \brief Traversal support functions ... incomplete-documentation
413
414 These functions have been made public as part of the design, but they are suggested for internal use
415 or by particularly knowledgable users for specialized tools or applications.
416 */
417 /* */
418
419 // DQ (11/26/2005): Support for visitor pattern mechanims
420 // (inferior to ROSE traversal mechanism, experimental).
424
425 /* DXN (08/09/2010): support for the classic visitor pattern done in GoF */
427 virtual void accept (ROSE_VisitorPattern & visitor) override;
428
429 // DQ (12/26/2005): Support for traversal based on the memory pool
432 static void traverseMemoryPoolNodes(ROSE_VisitTraversal & visit);
433
437
438 // DQ (2/9/2006): Added to support traversal over single representative of each IR node
439 // This traversal helps support internal tools that call static member functions.
440 // note: this function operates on the memory pools.
443 static void visitRepresentativeNode (ROSE_VisitTraversal & visit);
444 /* */
445
446 public:
447 /* NodeId support functions */
449 static SgNode* getNodeByNodeId(VariantT variantT, size_t poolIdx, size_t itemIdx);
452 static SgAsmNERelocEntry* getNodeByNodeIdInternal(size_t poolIdx, size_t itemIdx);
455 static std::string getNodeIdString(SgAsmNERelocEntry* sgnode);
456 static std::string getNodeIdStringInternal(SgAsmNERelocEntry* sgnode);
457
458 public:
459 /* name Memory Allocation Functions
460 \brief Memory allocations functions ... incomplete-documentation
461
462 These functions have been made public as part of the design, but they are suggested for internal use
463 or by particularly knowledgable users for specialized tools or applications.
464 */
465 /* */
466
477 virtual bool isInMemoryPool() override;
478
489 virtual void checkDataMemberPointersIfInMemoryPool() override;
490
491 // DQ (4/30/2006): Modified to be a const function.
506 virtual std::vector<std::pair<SgNode*,std::string> > returnDataMemberPointers() const override;
507
518
530 virtual long getChildIndex( SgNode* childNode ) const override;
531
532 // DQ (9/2/2015): Since this function is generated by ROSETTA, we can't define the
533 // comment here (changed to be a C style comment and not be a doxygen comment).
534 /* \brief Constructor for use by AST File I/O Mechanism
535
536 This constructor permits the IR node to be rebuilt from the contiguously arranged data in memory
537 which obtained via fast binary file I/O from disk.
538 */
539 // SgAsmNERelocEntry( SgAsmNERelocEntryStorageClass& source );
540
541
542
543
544
545 // JH (10/24/2005): methods added to support the ast file IO
546 private:
547
548 /* name AST Memory Allocation Support Functions
549 \brief Memory allocations support....
550
551 These functions handle the low leve support of the memory allocation scheme which permits IR nodes to be allocated
552 in large contiguous blocks to reduce memory fragmentation, improve performance, support specialized access (AST traversals),
553 and support the AST File I/O Mechanism.
554 */
555 /* */
556
557 /* JH (10/24/2005): Two typedefs. The TestType notes the type every pointer is cast to before
558 we compare them. Since I had several problems with this, I decided to make a typdef to ensure
559 that I use the same type everywhere, if any changes are made. THe second one declares the type
560 (actually unsigned long) where teh pointer address gets converted to. On 64 bit platforms this
561 might got changed, but unfortunatly, the return types are still unsigned longs. There exists
562 a correspinding one in the AST_FILE_IO class!
563 */
564 // DQ (9/2/2015): This typedef is no longer used, we can't define the
565 // comment here (changed to be a C style comment and not be a doxygen comment).
566 /* \brief Typedef used for low level memory access.
567 */
568 // typedef unsigned char* TestType;
569
570 // DQ (9/2/2015): This typedef is no longer used, we can't define the
571 // comment here (changed to be a C style comment and not be a doxygen comment).
572 /* \brief Typedef used to hold memory addresses as values.
573 */
574 // typedef unsigned long AddressType;
575
576
577
578 // necessary, to have direct access to the p_freepointer and the private methods !
580 friend class AST_FILE_IO;
581
583 friend class SgAsmNERelocEntryStorageClass;
584
586 friend class AstSpecificDataManagingClass;
587
589 friend class AstSpecificDataManagingClassStorageClass;
590 public:
592 SgAsmNERelocEntry( const SgAsmNERelocEntryStorageClass& source );
593
594 // private: // JJW hack
595 /*
596 name AST Memory Allocation Support Variables
597 Memory allocations support variables
598
599 These variables handle the low level support of the memory allocation scheme which permits IR nodes to be allocated
600 in large contiguous blocks to reduce memory fragmentation, improve performance, support specialized access (AST traversals),
601 and support the AST File I/O Mechanism.
602 */
603 /* */
604
605 public:
606
607 // DQ (11/21/2009): Added function to add new Regular Expression attributes and return pointer
608 // to current node (so that it will work cleanly with build functions to specify patterns).
609 // virtual SgNode* addRegExpAttribute();
616
617#ifndef _MSC_VER
618// Rasmussen (04/17/2019): Support for ATerms has been deprecated as it is no longer needed
619// and likely never fully implemented nor tested. Files remain in the src tree but are no
620// longer built.
621#define BUILD_ATERM_SUPPORT 0
622 #if BUILD_ATERM_SUPPORT
623 #ifdef ROSE_USE_ROSE_ATERM_SUPPORT
624 // DQ (10/4/2014): Adding ATerm support to ROSE.
634 // Rasmussen (1/7/2019): Added override to kill warning messages of overridden virtual function
635 virtual ATerm generate_ATerm() override;
636
638 virtual void generate_ATerm_Annotation(ATerm & term) override;
639 #endif
640 #endif // BUILD_ATERM_SUPPORT
641#endif
642 // These can't be virtual functions since we don't yet know what IR node to build (until we have read the aterm).
643 // virtual generate_AST(ATerm & term);
644 // virtual void read_ATerm_Annotation(ATerm & term);
645
646// *** COMMON CODE SECTION ENDS HERE ***
647
648
649// End of memberFunctionString
650// Start of memberFunctionString
651/* #line 710 "/workspace/src/ROSETTA/Grammar/Node.code" */
652
653 // the generated cast function
654 // friend ROSE_DLL_API SgAsmNERelocEntry* isSgAsmNERelocEntry ( SgNode* s );
655
656 typedef SgAsmExecutableFileFormat base_node_type;
657
658
659// End of memberFunctionString
660
661
662
663
664
665
666
667
668
669
670 protected:
671// Start of memberFunctionString
672SgAsmNERelocEntry::NERelocSrcType p_src_type;
673
674// End of memberFunctionString
675// Start of memberFunctionString
676SgAsmNERelocEntry::NERelocModifiers p_modifier;
677
678// End of memberFunctionString
679// Start of memberFunctionString
680SgAsmNERelocEntry::NERelocTgtType p_tgt_type;
681
682// End of memberFunctionString
683// Start of memberFunctionString
684SgAsmNERelocEntry::NERelocFlags p_flags;
685
686// End of memberFunctionString
687// Start of memberFunctionString
689
690// End of memberFunctionString
691// Start of memberFunctionString
693
694// End of memberFunctionString
695// Start of memberFunctionString
697
698// End of memberFunctionString
699// Start of memberFunctionString
701
702// End of memberFunctionString
703// Start of memberFunctionString
705
706// End of memberFunctionString
707
710 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, SgAsmNERelocEntry::NERelocModifiers,&SgAsmNERelocEntry::p_modifier>;
711 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, SgAsmNERelocEntry::NERelocTgtType,&SgAsmNERelocEntry::p_tgt_type>;
712 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, SgAsmNERelocEntry::NERelocFlags,&SgAsmNERelocEntry::p_flags>;
713 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, Rose::BinaryAnalysis::Address,&SgAsmNERelocEntry::p_src_offset>;
714 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, SgAsmNERelocEntry::iref_type,&SgAsmNERelocEntry::p_iref>;
715 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, SgAsmNERelocEntry::iord_type,&SgAsmNERelocEntry::p_iord>;
716 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, SgAsmNERelocEntry::iname_type,&SgAsmNERelocEntry::p_iname>;
717 friend struct Rose::Traits::generated::describe_field_t<SgAsmNERelocEntry, SgAsmNERelocEntry::osfixup_type,&SgAsmNERelocEntry::p_osfixup>;
718
719/* #line 21 "/workspace/src/ROSETTA/Grammar/grammarClassDeclarationMacros.macro" */
720
721
722 };
723#endif
724
725// postdeclarations for SgAsmNERelocEntry
726
727/* #line 728 "../../../src/frontend/SageIII//SgAsmNERelocEntry.h" */
728
729/* #line 27 "/workspace/src/ROSETTA/Grammar/grammarClassDeclarationMacros.macro after subst for $POSTDECLARATIONS" */
730
731/* #line 28 "/workspace/src/ROSETTA/Grammar/grammarClassDeclarationMacros.macro" */
732
733
734/* #line 735 "../../../src/frontend/SageIII//SgAsmNERelocEntry.h" */
735
736#endif // ROSE_SgAsmNERelocEntry_H
737
Class holding static data and functions supporting File I/O.
Definition AST_FILE_IO.h:19
Attribute containing a regex expression as a string.
Base class for many binary analysis nodes.
void initializeProperties()
Initialize all properties that have explicit initial values.
Contiguous region of a file.
Supporting class from copy mechanism within ROSE.
Definition sageCopy.h:26
This class represents the base class for all IR nodes within Sage III.
virtual RTIReturnType roseRTI()
return C++ Runtime-Time-Information
virtual size_t get_numberOfTraversalSuccessors() const
return number of children in the traversal successor list
virtual std::vector< std::string > get_traversalSuccessorNamesContainer() const
container of names of variables or container indices used used in the traversal to access AST success...
virtual void debugSerializationEnd(const char *className)
Called by generated serializers.
static std::string getNodeIdString(SgNode *sgnode)
compute the NodeId for a particular SgNode*.
virtual bool isInMemoryPool()
FOR INTERNAL USE This is used in internal tests to verify that all IR nodes are allocated from the he...
int variant() const
Older version function returns enum value "NODE".
virtual void processDataMemberReferenceToPointers(ReferenceToPointerHandler *)
FOR INTERNAL USE Processes pairs of references to SgNode* and strings for use in AST tools
virtual size_t get_childIndex(SgNode *child) const
index-based access to traversal successors by child node
virtual std::vector< SgNode * > get_traversalSuccessorContainer() const
container of pointers to AST successor nodes used in the traversal overridden in every class by gener...
virtual VariantT variantT() const
returns new style SageIII enum values
virtual long getChildIndex(SgNode *childNode) const
FOR INTERNAL USE Returns a unique index value for the childNode in the list of children at this IR no...
virtual void debugSerializationBegin(const char *className)
Called by generated serializers.
virtual SgNode * get_traversalSuccessorByIndex(size_t idx) const
index-based access to traversal successors by index number
virtual std::string class_name() const
returns a string representing the class name
static void visitRepresentativeNode(ROSE_VisitTraversal &visit)
FOR INTERNAL USE Support for type-based traversal.
virtual void checkDataMemberPointersIfInMemoryPool()
FOR INTERNAL USE This is used in internal tests to verify that all IR nodes are allocated from the he...
static size_t numberOfNodes()
Returns the total number of IR nodes of this type.
virtual void accept(ROSE_VisitorPattern &visitor)
support for the classic visitor pattern done in GoF
static void traverseMemoryPoolVisitorPattern(ROSE_VisitorPattern &visitor)
FOR INTERNAL USE Support for visitor pattern.
void executeVisitorMemberFunction(ROSE_VisitorPattern &visitor)
FOR INTERNAL USE Support for visitor pattern.
static SgNode * getNodeByNodeId(VariantT variantT, size_t poolIdx, size_t itemIdx)
Find a node by its variant type, pool index, and item index.
static size_t memoryUsage()
Returns the size in bytes of the total memory allocated for all IR nodes of this type.
static void traverseMemoryPoolNodes(ROSE_VisitTraversal &visit)
FOR INTERNAL USE Support for visitor pattern over all IR nodes by type of IR node.
virtual const char * sage_class_name() const
generates string representing the class name: (e.g. for SgNode returns "SgNode").
virtual std::vector< std::pair< SgNode *, std::string > > returnDataMemberPointers() const
FOR INTERNAL USE Returns STL vector of pairs of SgNode* and strings for use in AST tools
static SgNode * getNodeByNodeIdInternal(size_t poolIdx, size_t itemIdx)
FOR INTERNAL USE Find an SgNode from its memory pool and location therin.
SgNode * addRegExpAttribute(std::string s, AstRegExAttribute *a)
Support for AST matching using regular expression.
std::uint64_t Address
Address.
Definition Address.h:11
void serialize(std::ostream &output, Graph &graph)
Serialize a graph into a stream of bytes.
void copy(const Word *src, const BitRange &srcRange, Word *dst, const BitRange &dstRange)
Copy some bits.
const char * NERelocSrcType(int64_t)
Convert SgAsmNERelocEntry::NERelocSrcType enum constant to a string.
const char * NERelocFlags(int64_t)
Convert SgAsmNERelocEntry::NERelocFlags enum constant to a string.
const char * NERelocModifiers(int64_t)
Convert SgAsmNERelocEntry::NERelocModifiers enum constant to a string.
const char * NERelocTgtType(int64_t)
Convert SgAsmNERelocEntry::NERelocTgtType enum constant to a string.