r48111 | pierre | 2021-01-08 12:05:29 +0100 (Fri, 08 Jan 2021) | 1 line

Add setting of all optimization debug macros with single DEBUG_ALL_OPT macro
------------------------------------------------------------------------
--- Merging r48111 into '.':
U    compiler/fpcdefs.inc
--- Recording mergeinfo for merge of r48111 into '.':
 U   .
------------------------------------------------------------------------
r48112 | pierre | 2021-01-08 12:13:43 +0100 (Fri, 08 Jan 2021) | 1 line

 Fix compilation with -dALLOCREGDEBUG
------------------------------------------------------------------------
--- Merging r48112 into '.':
U    compiler/aoptobj.pas
--- Recording mergeinfo for merge of r48112 into '.':
 G   .

git-svn-id: branches/fixes_3_2@49497 -
This commit is contained in:
pierre 2021-06-11 16:08:33 +00:00
parent a092e59200
commit 1d3acf10c7
2 changed files with 29 additions and 6 deletions

View File

@ -1182,12 +1182,10 @@ Unit AoptObj;
removedSomething := false;
firstRemovedWasAlloc := false;
{$ifdef allocregdebug}
hp := tai_comment.Create(strpnew('allocating '+std_regname(newreg(R_INTREGISTER,supreg,R_SUBWHOLE))+
' from here...'));
insertllitem(asml,p1.previous,p1,hp);
hp := tai_comment.Create(strpnew('allocated '+std_regname(newreg(R_INTREGISTER,supreg,R_SUBWHOLE))+
' till here...'));
insertllitem(asml,p2,p2.next,hp);
hp := tai_comment.Create(strpnew('allocating '+std_regname(reg)+' from here...'));
insertllitem(p1.previous,p1,hp);
hp := tai_comment.Create(strpnew('allocated '+std_regname(reg)+' till here...'));
insertllitem(p2,p2.next,hp);
{$endif allocregdebug}
{ do it the safe way: always allocate the full super register,
as we do no register re-allocation in the peephole optimizer,

View File

@ -32,6 +32,31 @@
{$define USEINLINE}
{$endif EXTDEBUG}
{$ifdef DEBUG_ALL_OPT}
{ for aopt unit }
{$define DEBUG_OPTALLOC}
{$define DEBUG_INSTRUCTIONREGISTERDEPENDENCIES}
{for CPU/aoptcpu unit }
{$define DEBUG_AOPTCPU}
{$define DEBUG_PREREGSCHEDULER (arm specific) }
{ for aoptobj unit }
{$define DEBUG_AOPTOBJ}
{$define ALLOCREGDEBUG}
{ for optconstprop unit }
{$define DEBUG_CONSTPROP}
{ for optcse unit }
{$define CSEDEBUG}
{ for optdeadstore unit }
{$define DEBUG_DEADSTORE}
{ for optdfa unit }
{$define DEBUG_DFA}
{ for optloop unit }
{$define DEBUG_OPTFORLOOP}
{$define DEBUG_OPTSTRENGTH}
{ for optvirt unit }
{$define DEBUG_DEVIRT}
{$endif}
{$define USEEXCEPT}
{ This fake CPU is used to allow incorporation of globtype unit