Added tarval_sub_bits() fucntion to access the (binary) bitpattern of a tarval.
[libfirm] / ir / tv / tv_t.h
1 /* Declarations for Target Values.
2    Copyright (C) 1995, 1996 Christian von Roques */
3
4 /**
5 * @file tv_t.h
6 *
7 * @author Christian von Roques
8 */
9
10 /* $Id$ */
11
12 #ifndef _TV_T_H_
13 #define _TV_T_H_
14
15 #include "tv.h"
16 #include "xprintf.h"
17
18 /**
19  * This struct represents the aforementioned tarvals.
20  *
21  * A tarval struct consists of an internal representation of the
22  * value and some additional fields further describing the value.
23  *
24  * ATTRIBUTES:
25  *   - ir_mode *mode     The mode of the stored value
26  *   - void *value       The internal representation
27  *
28  * @sa
29  *   irmode.h for predefined modes
30  */
31 struct tarval {
32     ir_mode *mode;              /**< the mode of the stored value */
33     const void *value;          /**< the value stored in an internal way... */
34     unsigned int length;        /**< the length of the stored value */
35 };
36
37 /** xfprint output */
38 int tarval_print (XP_PAR1, const xprintf_info *, XP_PARN);
39
40 /** remove tarval representing an entity that is about to be destroyed */
41 void free_tarval_entity(entity *ent);
42
43 #endif /* _TV_T_H_ */