In order to disable tcg, the first phase is to split some tcg code and separate those tcg related files into one directory. The next phase will disable tcg more easily and cleanly. In the first phase, there are four patches to deal with split code and separate files. 1)split the tcg exec code. a)split the tcg accelerators from accel.c file and re-name tcg accelerator to tcg-all.c, like kvm-all.c did. b)create one accel directory, which will include kvm, tcg and general exec files. 2)move cputlb.c, cpu-exec-common.c and cpu-exec.c related tcg exec file into accel/tcg/ subdirectory. 3)move tcg related backend files into accel/tcg/ directory those files include translate-all.(ch), translate-common.c, tci.c and tcg-runtime.c. 4)move kvm and exec.c file. a)move kvm related accelerator files into accel/kvm/ directory. b)move exec.c in accel/ directory. c)stubs/ directory was created for kvm and tcg stub files.
after those changes are done, the file tree like below accel ????????? accel.c ????????? exec.c ????????? kvm ??? ????????? kvm-all.c ??? ????????? Makefile.objs ??? ????????? trace-events ????????? Makefile.objs ????????? stubs ??? ????????? kvm-stub.c ??? ????????? Makefile.objs ????????? tcg ????????? cpu-exec.c ????????? cpu-exec-common.c ????????? cputlb.c ????????? Makefile.objs ????????? tcg-all.c ????????? tcg-runtime.c ????????? tci.c ????????? trace-events ????????? translate-all.c ????????? translate-all.h ????????? translate-common.c 3 directories, 19 files v3: squash patches and move tcg related backend files to accel/tcg/ according to Paolo's comments. add kvm and tcg exec related patches into one patchset. Yang Zhong (4): accel: split the tcg accelerator from accel.c file tcg: move tcg related files into accel/tcg/ subdirectory tcg: move tcg backend files into accel/tcg/ accel: move kvm related accelerator files into accel/ Makefile.objs | 3 +- Makefile.target | 10 +--- accel/Makefile.objs | 5 ++ accel.c => accel/accel.c | 27 ---------- exec.c => accel/exec.c | 0 accel/kvm/Makefile.objs | 1 + kvm-all.c => accel/kvm/kvm-all.c | 2 +- accel/kvm/trace-events | 13 +++++ accel/stubs/Makefile.objs | 1 + kvm-stub.c => accel/stubs/kvm-stub.c | 0 accel/tcg/Makefile.objs | 4 ++ cpu-exec-common.c => accel/tcg/cpu-exec-common.c | 0 cpu-exec.c => accel/tcg/cpu-exec.c | 2 +- cputlb.c => accel/tcg/cputlb.c | 0 accel/tcg/tcg-all.c | 61 ++++++++++++++++++++++ tcg-runtime.c => accel/tcg/tcg-runtime.c | 0 tci.c => accel/tcg/tci.c | 0 accel/tcg/trace-events | 10 ++++ translate-all.c => accel/tcg/translate-all.c | 2 +- translate-all.h => accel/tcg/translate-all.h | 0 translate-common.c => accel/tcg/translate-common.c | 0 configure | 2 +- trace-events | 21 -------- 23 files changed, 103 insertions(+), 61 deletions(-) create mode 100644 accel/Makefile.objs rename accel.c => accel/accel.c (87%) rename exec.c => accel/exec.c (100%) create mode 100644 accel/kvm/Makefile.objs rename kvm-all.c => accel/kvm/kvm-all.c (99%) create mode 100644 accel/kvm/trace-events create mode 100644 accel/stubs/Makefile.objs rename kvm-stub.c => accel/stubs/kvm-stub.c (100%) create mode 100644 accel/tcg/Makefile.objs rename cpu-exec-common.c => accel/tcg/cpu-exec-common.c (100%) rename cpu-exec.c => accel/tcg/cpu-exec.c (99%) rename cputlb.c => accel/tcg/cputlb.c (100%) create mode 100644 accel/tcg/tcg-all.c rename tcg-runtime.c => accel/tcg/tcg-runtime.c (100%) rename tci.c => accel/tcg/tci.c (100%) create mode 100644 accel/tcg/trace-events rename translate-all.c => accel/tcg/translate-all.c (99%) rename translate-all.h => accel/tcg/translate-all.h (100%) rename translate-common.c => accel/tcg/translate-common.c (100%) -- 1.9.1