Re: New backend
Segher Boessenkool <[email protected]> Wed, 31 Dec 2025 09:35:25 -0600
| Newsgroups | gmane.comp.gcc.help |
|---|---|
| Message-ID | <aVVCvVdwekAZcTjJ@gate> |
Hi! On Wed, Dec 31, 2025 at 04:15:31PM +0100, BERTRAND Joël wrote: > NOTICE_UPDATE_CC asks a lot of modifications in m6809.md (cc0 has to be > replaced by REG:CC HARD_CC_REGNUM. Yeah, CC0 has gone away. And good riddance :-) And yeah, using something like you do is a good way to do things on most targets. > Now build crashes with following error : > > build/genconditions ../../gcc-15.2.0/gcc/common.md > ../../gcc-15.2.0/gcc/config/m6809/m6809.md > tmp-condmd.cc > /bin/bash ../../gcc-15.2.0/gcc/../move-if-change tmp-condmd.cc > build/gencondmd.cc > echo timestamp > s-conditions > build/genpreds -c ../../gcc-15.2.0/gcc/common.md > ../../gcc-15.2.0/gcc/config/m6809/m6809.md > tmp-constrs.h > /bin/bash ../../gcc-15.2.0/gcc/../move-if-change tmp-constrs.h tm-constrs.h > echo timestamp > s-constrs-h > g++ -c -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE > -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall > -Wno-error=narrowing -Wwrite-strings -Wcast-qual > -Wmissing-format-attribute -Wconditionally-supported > -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros > -Wno-overlength-strings -DHAVE_CONFIG_H -DGENERATOR_FILE -I. -Ibuild > -I../../gcc-15.2.0/gcc -I../../gcc-15.2.0/gcc/build > -I../../gcc-15.2.0/gcc/../include > -I../../gcc-15.2.0/gcc/../libcpp/include \ > -o build/gencondmd.o build/gencondmd.cc > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:2350:22: error: > ‘power_of_two_p’ was not declared in this scope > 2350 | "reload_completed && power_of_two_p (INTVAL (operands[1]) + 1)" > | ^~~~~~~~~~~~~~ You can use something like "exact_log2 (...) >= 0". > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:2350:22: error: > ‘power_of_two_p’ was not declared in this scope > 2350 | "reload_completed && power_of_two_p (INTVAL (operands[1]) + 1)" > | ^~~~~~~~~~~~~~ > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:1620:2: error: > ‘far_functionp’ was not declared in this scope; did you mean > ‘leaf_function_p’? > 1620 | "far_functionp (operands[0])" > | ^~~~~~~~~~~~~ > | leaf_function_p > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:1620:2: error: > ‘far_functionp’ was not declared in this scope; did you mean > ‘leaf_function_p’? > 1620 | "far_functionp (operands[0])" > | ^~~~~~~~~~~~~ > | leaf_function_p No idea what these are about, that is something specific to your backend? > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:2064:2: error: > ‘m6809_match_peephole’ was not declared in this scope > 2064 | "m6809_match_peephole2 (PEEP_LSRB_ADCB, PEEP_END)" > | ^~~~~~~~~~~~~~~~~~~~~ > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:2064:2: error: > ‘m6809_match_peephole’ was not declared in this scope > 2064 | "m6809_match_peephole2 (PEEP_LSRB_ADCB, PEEP_END)" > | ^~~~~~~~~~~~~~~~~~~~~ > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:2213:2: error: > ‘m6809_match_peephole’ was not declared in this scope > 2213 | "m6809_match_peephole2 (PEEP_DEC_IMPLIES_CC, PEEP_END)" > | ^~~~~~~~~~~~~~~~~~~~~ > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:2213:2: error: > ‘m6809_match_peephole’ was not declared in this scope > 2213 | "m6809_match_peephole2 (PEEP_DEC_IMPLIES_CC, PEEP_END)" > | ^~~~~~~~~~~~~~~~~~~~~ > ../../gcc-15.2.0/gcc/config/m6809/m6809.md:2292:22: error: > ‘m6809_match_peephole2’ was not declared in this scope > > Of courses, these functions were defined in m6809.cc. I suppose I have > forgotten something. This stuff is not in the tarball you previously provided? Segher