Hi Lehua, > I think the purpose of this testcase is to check whether the modifications to > the stack frame are as expected, so it is necessary to specify exactly whether > three or four registers are saved. But I think its need to add another > testcase > which use another option -mcmodel=medany for coverage.
In general I'm fine with this small change of course, I just wonder if the test case is not brittle anyway. From what I can tell the respective change is independent of the actual number of registers so maybe it's enough to not compare the fully body but just make sure the addis are not present? That way, the test could also work for -march=rv64 (which saves one register less anyway regardless of mcmodel - but the change still helps) or maybe even with instruction scheduling. Would you mind checking this still? Thanks. If it turns out not to be possible, let's stick with the medany fix for now and add a TODO. Regards Robin