pub/libvex_ir.h \
pub/libvex.h
-PRIV_HEADERS = priv/host-x86/hdefs.h \
- priv/host-generic/host_regs.h \
+PRIV_HEADERS = priv/host-x86/hdefs.h \
+ priv/host-generic/h_generic_regs.h \
priv/main/vex_globals.h \
priv/main/vex_util.h \
- priv/guest-x86/x86guest_defs.h
+ priv/guest-x86/gdefs.h
-LIB_OBJS = priv/ir/ir_defs.o \
+LIB_OBJS = priv/ir/irdefs.o \
priv/main/vex_main.o \
priv/main/vex_globals.o \
priv/main/vex_util.o \
- priv/host-x86/hdefs.o \
- priv/host-x86/isel.o \
- priv/host-generic/host_regs.o \
+ priv/host-x86/hdefs.o \
+ priv/host-x86/isel.o \
+ priv/host-generic/h_generic_regs.o \
priv/host-generic/reg_alloc.o \
- priv/guest-x86/x86helpers.o \
- priv/guest-x86/x86toIR.o
+ priv/guest-x86/ghelpers.o \
+ priv/guest-x86/toIR.o
PUB_INCLUDES = -Ipub
-PRIV_INCLUDES = -Ipriv/ir -Ipriv/main -Ipriv/host-generic \
- -Ipriv/host-x86 -Ipriv/guest-x86
-
-APP_OBJS = test_main.o
+# Do not add any priv/host-ARCH or priv/guest-ARCH directories to this
+# list, as they contain duplicate file names (each host has a hdefs.h,
+# for example).
+PRIV_INCLUDES = -Ipriv
CC = gcc341
rm -f hacked104/valgrind.so
(cd hacked104 && make install)
-#all: libvex.a $(APP_OBJS)
-# $(CC) $(CCFLAGS) -o vex $(APP_OBJS) libvex.a
+vex: libvex.a test_main.o
+ $(CC) $(CCFLAGS) -o vex libvex.a test_main.o
libvex.a: $(LIB_OBJS)
rm -f libvex.a
ar clq libvex.a $(LIB_OBJS)
clean:
- rm -f $(APP_OBJS) $(LIB_OBJS) libvex.a vex
+ rm -f $(LIB_OBJS) libvex.a vex test_main.o
(cd hacked104 && make clean)
$(CC) $(CCFLAGS) $(PUB_INCLUDES) -o test_main.o \
-c test_main.c
-priv/ir/ir_defs.o: $(ALL_HEADERS) priv/ir/ir_defs.c
- $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/ir/ir_defs.o \
- -c priv/ir/ir_defs.c
+priv/ir/irdefs.o: $(ALL_HEADERS) priv/ir/irdefs.c
+ $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/ir/irdefs.o \
+ -c priv/ir/irdefs.c
priv/main/vex_main.o: $(ALL_HEADERS) priv/main/vex_main.c
$(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/main/vex_main.o \
$(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/host-x86/isel.o \
-c priv/host-x86/isel.c
-priv/host-generic/host_regs.o: $(ALL_HEADERS) priv/host-generic/host_regs.c
- $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/host-generic/host_regs.o \
- -c priv/host-generic/host_regs.c
+priv/host-generic/h_generic_regs.o: $(ALL_HEADERS) priv/host-generic/h_generic_regs.c
+ $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/host-generic/h_generic_regs.o \
+ -c priv/host-generic/h_generic_regs.c
priv/host-generic/reg_alloc.o: $(ALL_HEADERS) priv/host-generic/reg_alloc.c
$(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/host-generic/reg_alloc.o \
-c priv/host-generic/reg_alloc.c
-priv/guest-x86/x86toIR.o: $(ALL_HEADERS) priv/guest-x86/x86toIR.c
- $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/guest-x86/x86toIR.o \
- -c priv/guest-x86/x86toIR.c
+priv/guest-x86/toIR.o: $(ALL_HEADERS) priv/guest-x86/toIR.c
+ $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/guest-x86/toIR.o \
+ -c priv/guest-x86/toIR.c
-priv/guest-x86/x86helpers.o: $(ALL_HEADERS) priv/guest-x86/x86helpers.c
- $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/guest-x86/x86helpers.o \
- -c priv/guest-x86/x86helpers.c
+priv/guest-x86/ghelpers.o: $(ALL_HEADERS) priv/guest-x86/ghelpers.c
+ $(CC) $(CCFLAGS) $(ALL_INCLUDES) -o priv/guest-x86/ghelpers.o \
+ -c priv/guest-x86/ghelpers.c
/*---------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (x86helpers.c) is ---*/
+/*--- This file (guest-x86/ghelpers.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*---------------------------------------------------------------*/
#include "libvex_basictypes.h"
#include "libvex_ir.h"
-#include "vex_util.h"
-#include "x86guest_defs.h"
+
+#include "main/vex_util.h"
+#include "guest-x86/gdefs.h"
/* This file contains helper functions for x86 guest code.
Calls to these functions are generated by the back end.
/*---------------------------------------------------------------*/
-/*--- end x86helpers.c ---*/
+/*--- end guest-x86/ghelpers.c ---*/
/*---------------------------------------------------------------*/
/*--------------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (x86toIR.c) is ---*/
+/*--- This file (guest-x86/toIR.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*--------------------------------------------------------------------*/
#include "libvex_basictypes.h"
#include "libvex_ir.h"
#include "libvex.h"
-#include "vex_util.h"
-#include "vex_globals.h"
-#include "x86guest_defs.h"
+
+#include "main/vex_util.h"
+#include "main/vex_globals.h"
+#include "guest-x86/gdefs.h"
/*------------------------------------------------------------*/
#undef DIS
/*--------------------------------------------------------------------*/
-/*--- end vg_to_ucode.c ---*/
+/*--- end guest-x86/toIR.c ---*/
/*--------------------------------------------------------------------*/
/*---------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (host_regs.c) is ---*/
+/*--- This file (host-generic/h_generic_regs.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*---------------------------------------------------------------*/
#include "libvex_basictypes.h"
#include "libvex.h"
-#include "vex_util.h"
-#include "host_regs.h"
+#include "main/vex_util.h"
+#include "host-generic/h_generic_regs.h"
HReg mkHReg ( UInt regno, HRegClass rc, Bool virtual )
/*---------------------------------------------------------------*/
-/*--- end host_regs.c ---*/
+/*--- end host-generic/h_generic_regs.c ---*/
/*---------------------------------------------------------------*/
/*---------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (reg_alloc.c) is ---*/
+/*--- This file (host-generic/reg_alloc.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*---------------------------------------------------------------*/
#include "libvex_basictypes.h"
#include "libvex.h"
-#include "vex_util.h"
-#include "host_regs.h"
+#include "main/vex_util.h"
+#include "host-generic/h_generic_regs.h"
/* Set to 1 for lots of debugging output. */
#define DEBUG_REGALLOC 0
/*---------------------------------------------------------------*/
-/*--- reg_alloc.c ---*/
+/*--- host-generic/reg_alloc.c ---*/
/*---------------------------------------------------------------*/
/*---------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (x86h_defs.c) is ---*/
+/*--- This file (host-x86/hdefs.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*---------------------------------------------------------------*/
#include "libvex_basictypes.h"
#include "libvex.h"
-#include "vex_util.h"
-#include "host_regs.h"
-#include "x86host_defs.h"
+#include "main/vex_util.h"
+#include "host-generic/h_generic_regs.h"
+#include "host-x86/hdefs.h"
/* --------- Registers. --------- */
/*---------------------------------------------------------------*/
-/*--- end x86h_defs.c ---*/
+/*--- end host-x86/hdefs.c ---*/
/*---------------------------------------------------------------*/
/*---------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (isel_x86.c) is ---*/
+/*--- This file (host-x86/isel.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*---------------------------------------------------------------*/
#include "libvex_ir.h"
#include "libvex.h"
-#include "vex_util.h"
-#include "vex_globals.h"
-#include "host_regs.h"
-#include "x86host_defs.h"
+#include "main/vex_util.h"
+#include "main/vex_globals.h"
+#include "host-generic/h_generic_regs.h"
+#include "host-x86/hdefs.h"
/*---------------------------------------------------------*/
/*---------------------------------------------------------------*/
-/*--- end isel_x86.c ---*/
+/*--- end host-x86/isel.c ---*/
/*---------------------------------------------------------------*/
/*---------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (ir_defs.c) is ---*/
+/*--- This file (ir/irdefs.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*---------------------------------------------------------------*/
#include "libvex_ir.h"
#include "libvex.h"
-#include "vex_util.h"
+#include "main/vex_util.h"
+
/*---------------------------------------------------------------*/
/*--- Printing the IR ---*/
/*---------------------------------------------------------------*/
-/*--- end ir_defs.c ---*/
+/*--- end ir/irdefs.c ---*/
/*---------------------------------------------------------------*/
/*---------------------------------------------------------------*/
/*--- ---*/
-/*--- This file (vex_main.c) is ---*/
+/*--- This file (main/vex_main.c) is ---*/
/*--- Copyright (c) 2004 OpenWorks LLP. All rights reserved. ---*/
/*--- ---*/
/*---------------------------------------------------------------*/
#include "libvex.h"
-#include "vex_globals.h"
-#include "vex_util.h"
-#include "host_regs.h"
-#include "x86host_defs.h"
-#include "x86guest_defs.h"
+#include "main/vex_globals.h"
+#include "main/vex_util.h"
+#include "host-generic/h_generic_regs.h"
+#include "host-x86/hdefs.h"
+#include "guest-x86/gdefs.h"
/* This file contains the top level interface to the library. */
/*---------------------------------------------------------------*/
-/*--- end vex_main.c ---*/
+/*--- end main/vex_main.c ---*/
/*---------------------------------------------------------------*/