summaryrefslogtreecommitdiffhomepage
path: root/ir/be/becopyopt_t.h
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2007-03-19 18:05:21 +0100
committerMatthias Braun <matze@braunis.de>2007-03-19 18:05:21 +0100
commit8535fe8732b0acf822be252812a7158ce5b8134a (patch)
tree7c90501572493f3bbcf2fd56183a135c5a99e5b2 /ir/be/becopyopt_t.h
parentded8c3995ddca132ef312a6fdeeba7eae2e42c43 (diff)
The big committ:
- Replace limit callback in register requirements with a simple bitset - Fix backends, generators and the rest of the code for the change register requirements structure - Eliminated the custom register_requirement structures in the backend, they are pointless now, use the normal arch_register_req_t - Fix TEMPLATE backend - Extract emitter framework from ia32 and provide generic header/code for it - Port TEMPLATE backend to new emitter - Extract gas specific emit stuff (declarations, sections) from ia32 backend and provide it as generic header/code. Make TEMPLATE backend use that - Remove several FIRM_DBG_REGISTERs from functions which are called very often. Before we had millions of string hashtable lookups because of that. The prefered way is to have 1 static debug module per file and initialize it in the module constructor. No passing around in environment structs and in no case should you dynamically register it in single functions.
Diffstat (limited to 'ir/be/becopyopt_t.h')
-rw-r--r--ir/be/becopyopt_t.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/ir/be/becopyopt_t.h b/ir/be/becopyopt_t.h
index 5c12ab8..48c795f 100644
--- a/ir/be/becopyopt_t.h
+++ b/ir/be/becopyopt_t.h
@@ -52,9 +52,10 @@ struct _copy_opt_t {
#define is_Perm(arch_env, irn) (arch_irn_classify(arch_env, irn) == arch_irn_class_perm)
#define is_Perm_Proj(arch_env, irn) (is_Proj(irn) && is_Perm(arch_env, get_Proj_pred(irn)))
-#define is_2addr_code(arch_env, irn, req) (arch_get_register_req(arch_env, req, irn, -1)->type == arch_register_req_type_should_be_same)
-
-
+static INLINE int is_2addr_code(const arch_register_req_t *req)
+{
+ return req->type == arch_register_req_type_should_be_same;
+}
/******************************************************************************
____ _ _ _ _ _ _____ _