Commit 8802b693 authored by alex@thinkpad's avatar alex@thinkpad
Browse files

QEMU logging: moved IDC files into model subdirectories

(for consistency with romcpy shell files)

--HG--
branch : qemu
parent 5a933e70396f
......@@ -279,7 +279,7 @@ static FILE * idc = NULL;
static void close_idc(void)
{
fprintf(idc, "}\n");
fclose(idc);
fclose(idc); idc = 0;
fprintf(stderr, "%s saved.\n", idc_path);
}
......@@ -290,7 +290,7 @@ static void eos_idc_log_call(EOSState *s, CPUState *cpu, CPUARMState *env,
if (!idc)
{
snprintf(idc_path, sizeof(idc_path), "%s.idc", MACHINE_GET_CLASS(current_machine)->name);
snprintf(idc_path, sizeof(idc_path), "%s/calls.idc", s->model->name);
fprintf(stderr, "Exporting called functions to %s.\n", idc_path);
idc = fopen(idc_path, "w");
assert(idc);
......
......@@ -577,7 +577,7 @@ function test_calls_main {
echo -n ' '
# wait until it the IDC no longer grows, up to 5 minutes
./wait_log.sh $CAM.idc 300 5 -q "^}"
./wait_log.sh $CAM/calls.idc 300 5 -q "^}"
echo
echo -n " "
......@@ -593,7 +593,7 @@ function test_calls_main {
# let's trim until matching the MD5 of $TEST-basic.idc
# this assumes the needles (expected test results) were created on a slower PC and/or using a smaller timeout
cat $CAM.idc | grep -o "MakeFunction(.*)" \
cat $CAM/calls.idc | grep -o "MakeFunction(.*)" \
> tests/$CAM/$TEST-basic.idc
# compute the MD5 of $TEST-basic.idc, line by line, until it matches its reference MD5
......@@ -636,8 +636,8 @@ function test_calls_main {
# also copy the IDC file for checking its MD5
# this works on old CF models too (40D), even if some nondeterminism is present
# the IDC needs trimming, too, as it doesn't always stop at the same line
cat $CAM.idc | sed -n "1,/MakeFunction($last_call/ p" > tests/$CAM/$TEST.idc
cat $CAM.idc | tail -n 2 >> tests/$CAM/$TEST.idc
cat $CAM/calls.idc | sed -n "1,/MakeFunction($last_call/ p" > tests/$CAM/$TEST.idc
cat $CAM/calls.idc | tail -n 2 >> tests/$CAM/$TEST.idc
# extract only the call address from IDC
# useful for checking when some additional info changes (e.g. comments)
......@@ -741,7 +741,7 @@ function test_calls_from {
# also copy the IDC file for checking its MD5
# this works on CF models too, even if some nondeterminism is present
cp $CAM.idc tests/$CAM/$TEST.idc
cp $CAM/calls.idc tests/$CAM/$TEST.idc
# extract only the call address from IDC
# useful for checking when some additional info changes (e.g. comments)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment