libFirm
firm_common.h File Reference

common firm declarations More...

#include "firm_types.h"
#include "begin.h"
#include "end.h"

Go to the source code of this file.

Enumerations

enum  firm_kind {
  k_BAD = 0, k_entity, k_type, k_ir_graph,
  k_ir_node, k_ir_mode, k_ir_op, k_tarval,
  k_ir_loop, k_ir_prog, k_ir_graph_pass, k_ir_prog_pass,
  k_ir_graph_pass_mgr, k_ir_prog_pass_mgr, k_ir_max
}
 a list of firm kinds Most important datastructures in firm contain a firm_kind field at the beginning so given void* pointer you can usually still guess the kind of thing the pointer points to. More...

Functions

void ir_init (void)
 Initializes the firm library.
void ir_finish (void)
 Frees all memory occupied by the firm library.
unsigned ir_get_version_major (void)
 returns the libFirm major version number
unsigned ir_get_version_minor (void)
 returns libFirm minor version number
const char * ir_get_version_revision (void)
 returns string describing libFirm revision
const char * ir_get_version_build (void)
 returns string describing libFirm build
firm_kind get_kind (const void *firm_thing)
 Returns the kind of a thing.

Detailed Description

common firm declarations

Author
Martin Trapp, Christian Schaefer, Goetz Lindenmaier

Definition in file firm_common.h.

Enumeration Type Documentation

enum firm_kind

a list of firm kinds Most important datastructures in firm contain a firm_kind field at the beginning so given void* pointer you can usually still guess the kind of thing the pointer points to.

This is used in debug helper functions and printers.

Enumerator:
k_BAD 

An invalid firm node.

k_entity 

An entity.

k_type 

A type.

k_ir_graph 

An IR graph.

k_ir_node 

An IR node.

k_ir_mode 

An IR mode.

k_ir_op 

An IR opcode.

k_tarval 

A tarval.

k_ir_loop 

A loop.

k_ir_prog 

A program representation (irp).

k_ir_graph_pass 

An ir_graph pass.

k_ir_prog_pass 

An ir_prog pass.

k_ir_graph_pass_mgr 

An ir_graph pass manager.

k_ir_prog_pass_mgr 

An ir_prog pass manager.

k_ir_max 

maximum value – illegal for firm nodes.

Definition at line 57 of file firm_common.h.

Function Documentation

firm_kind get_kind ( const void *  firm_thing)

Returns the kind of a thing.

Parameters
firm_thingpointer representing a firm object
void ir_finish ( void  )

Frees all memory occupied by the firm library.

const char* ir_get_version_build ( void  )

returns string describing libFirm build

unsigned ir_get_version_major ( void  )

returns the libFirm major version number

unsigned ir_get_version_minor ( void  )

returns libFirm minor version number

const char* ir_get_version_revision ( void  )

returns string describing libFirm revision

void ir_init ( void  )

Initializes the firm library.

Allocates default data structures.