Mercury Bugs - mercury  | ||||||||||
| View Issue Details | ||||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | |||||
| 0000039 | mercury | Bug | public | 2008-01-22 17:48 | 2009-11-27 02:03 | |||||
| Reporter | wangp | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Assigned To | wangp | |||||||||
| Priority | normal | Severity | minor | Reproducibility | always | |||||
| Status | resolved | Resolution | fixed | |||||||
| Platform | OS | OS Version | ||||||||
| Product Version | ||||||||||
| Target Version | Fixed in Version | |||||||||
| Summary | 0000039: gcc 4.1.2 on x86-64 miscompiles computed gotos | |||||||||
| Description | In compiler/purity.m we needed a work around to avoid a segfault while purity checking invalid/purity/purity.m. We get a segfault when jumping to the `unnecessary_promise_pure' branch. Happens with gcc 4.1.2 on x86-64, at gcc -O1 and above.  | |||||||||
| Additional Information | This also works around the problem. Note the volatile. #define MR_COMPUTED_GOTO(val, labels) \ { \ static MR_Code *jump_table[] = { \ labels \ }; \ volatile int val1 = (val); \ MR_GOTO(jump_table[val1]); \ }  | |||||||||
| Tags | No tags attached. | |||||||||
| Relationships | 
  | |||||||||
| Attached Files | ||||||||||
| Notes | |||||
| 
			 | 
	|||||
			
  | 
		
			
  | 
	||||
| Issue History | |||||
| Date Modified | Username | Field | Change | ||
|---|---|---|---|---|---|
| 2008-01-22 17:48 | wangp | New Issue | |||
| 2009-09-26 06:24 | pbone | Note Added: 0000190 | |||
| 2009-09-26 06:26 | pbone | Relationship added | related to 0000066 | ||
| 2009-11-24 00:18 | wangp | Status | new => assigned | ||
| 2009-11-24 00:18 | wangp | Assigned To | => wangp | ||
| 2009-11-27 02:03 | wangp | Status | assigned => resolved | ||
| 2009-11-27 02:03 | wangp | Resolution | open => fixed | ||