CACAO
Data Structures | Functions | Variables
instruction_gen Namespace Reference

Data Structures

class  Formatter
 
class  Template
 

Functions

def main
 
def burg
 

Variables

string cpp_header
 
string cpp_generation_disclaimer
 
string cpp_footer
 
list temps
 

Function Documentation

def instruction_gen.burg ( )

Definition at line 170 of file instruction_gen.py.

def instruction_gen.main (   temps)

Definition at line 123 of file instruction_gen.py.

Variable Documentation

string instruction_gen.cpp_footer
Initial value:
1 = """
2 /*
3  * These are local overrides for various environment variables in Emacs.
4  * Please do not remove this and leave it at the end of the file, where
5  * Emacs will automagically detect them.
6  * ---------------------------------------------------------------------
7  * Local variables:
8  * mode: c++
9  * indent-tabs-mode: t
10  * c-basic-offset: 4
11  * tab-width: 4
12  * End:
13  * vim:noexpandtab:sw=4:ts=4:
14  */
15 """

Definition at line 69 of file instruction_gen.py.

string instruction_gen.cpp_generation_disclaimer
Initial value:
1 = """/*
2 WARNING: THIS FILE IS AUTO-GENERATED! DO NOT ALTER!
3 Instead have a look at the generator ({generator})
4 and the input file ({input_file}).
5 */
6 
7 """

Definition at line 61 of file instruction_gen.py.

string instruction_gen.cpp_header
Initial value:
1 = """/* src/vm/jit/compiler2/{filename} - {file_desc}
2 
3  Copyright (C) 2013
4  CACAOVM - Verein zur Foerderung der freien virtuellen Maschine CACAO
5 
6  This file is part of CACAO.
7 
8  This program is free software; you can redistribute it and/or
9  modify it under the terms of the GNU General Public License as
10  published by the Free Software Foundation; either version 2, or (at
11  your option) any later version.
12 
13  This program is distributed in the hope that it will be useful, but
14  WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16  General Public License for more details.
17 
18  You should have received a copy of the GNU General Public License
19  along with this program; if not, write to the Free Software
20  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21  02110-1301, USA.
22 
23 */
24 
25 """

Definition at line 35 of file instruction_gen.py.

list instruction_gen.temps
Initial value:
1 = [
2  Template('InstructionDeclGen.inc','Instruction Declarations','class {name};\n',
3  cpp_header+cpp_generation_disclaimer,cpp_footer),
4  Template('InstructionIDGen.inc','Instruction IDs','{name}ID,\n',
5  cpp_header+cpp_generation_disclaimer,cpp_footer),
6  Template('InstructionToInstGen.inc','Instruction conversion methods',
7  'virtual {name}* to_{name}() {{ return NULL; }}\n',
8  cpp_header+cpp_generation_disclaimer,cpp_footer),
9  Template('InstructionNameSwitchGen.inc','Instruction name switch',
10  'case {name}ID: return "{name}";\n',
11  cpp_header+cpp_generation_disclaimer,cpp_footer),
12  Template('InstructionVisitorGen.inc','Instruction Visitor',
13  'virtual void visit({name}* I, bool copyOperands);\n',
14  cpp_header+cpp_generation_disclaimer,cpp_footer),
15  Template('InstructionVisitorImplGen.inc','Instruction Visitor',
16  'void InstructionVisitor::visit({name}* I, bool copyOperands) {{visit_default(I);}}\n',
17  cpp_header+cpp_generation_disclaimer,cpp_footer),
18  ]

Definition at line 275 of file instruction_gen.py.