Re: IF conversion bug with CC0

2016-04-04 Thread Dan
Got it! That even answers my second round of questions. Thank you! Dan On Tue, 2016-04-05 at 01:24 +0200, Eric Botcazou wrote: > > I took a quick look at Visium, and noticed arithmetic instructions in > > the .md file doing a lot of clobbering of the condition codes register. > > This doesn't

Re: IF conversion bug with CC0

2016-04-04 Thread Eric Botcazou
> I took a quick look at Visium, and noticed arithmetic instructions in > the .md file doing a lot of clobbering of the condition codes register. > This doesn't seem very efficient, since it prevents the arithmetic > instructions from being able to set the CC register and have that value > be used.

Re: IF conversion bug with CC0

2016-04-04 Thread Dan
I like this position--with good kind natured folks arguing over the best way to help me. ;P Thank you both. I took a quick look at Visium, and noticed arithmetic instructions in the .md file doing a lot of clobbering of the condition codes register. This doesn't seem very efficient, since it pre

Re: IF conversion bug with CC0

2016-04-04 Thread Jeff Law
On 04/04/2016 04:20 PM, Eric Botcazou wrote: From a 30 second view of your ISA, it appears that most arithmetic/logicals unconditionally set the condition codes. I would suggest modeling condition code handling similar to how it's done on the x86 port. No advertisement intended, but the Visi

Re: IF conversion bug with CC0

2016-04-04 Thread Eric Botcazou
> From a 30 second view of your ISA, it appears that most > arithmetic/logicals unconditionally set the condition codes. > > I would suggest modeling condition code handling similar to how it's > done on the x86 port. No advertisement intended, but the Visium architecture is the typical 32-bit

Re: IF conversion bug with CC0

2016-04-04 Thread Jeff Law
On 04/04/2016 03:13 PM, Dan wrote: Jeff, Thank you for your quick response! Yes, I have a custom ISA. I am building a custom back end. The project, in its current state, can be found at: http://opencores.com/project,zipcpu Can you tell me whether the difference between CC0 processing and no

Re: IF conversion bug with CC0

2016-04-04 Thread Dan
Jeff, Thank you for your quick response! Yes, I have a custom ISA. I am building a custom back end. The project, in its current state, can be found at: http://opencores.com/project,zipcpu Can you tell me whether the difference between CC0 processing and non-CC0 processing is a GCC difference

Re: IF conversion bug with CC0

2016-04-04 Thread Jeff Law
On 04/04/2016 02:19 PM, Dan wrote: Greetings! GCC is usually so perfect, that I hate to write, but ... I think I'm chasing down quite the bug in it and would appreciate some thought to the following. The code that causes the bug looks like: if (ptr) { *ptr = 1; } This code evaluates, in th

IF conversion bug with CC0

2016-04-04 Thread Dan
Greetings! GCC is usually so perfect, that I hate to write, but ... I think I'm chasing down quite the bug in it and would appreciate some thought to the following. The code that causes the bug looks like: if (ptr) { *ptr = 1; } This code evaluates, in the instruction set I am working with, i