Opened 5 years ago

Closed 5 years ago

#149 closed defect (fixed)

Incorrectly resolving asm statement operand names

Reported by: Thierry Delisle Owned by:
Priority: minor Component: cfa-cc
Version: 1.0 Keywords:


Given the following code :

static inline bool bts(volatile size_t * target, size_t bit ) {
	int result = 0;
	asm volatile(
		"LOCK btsq %[bit_asm], %[target_asm]\n\t"
            :"=@ccc" (result)
            : [target_asm] "m" (*target), [bit_asm] "r" (bit)
	return result != 0;

Cforall attempts to resolve the names target_asm and bit_asm. This behaviour is incorrect and the names should be left as is.

Change History (1)

comment:1 Changed 5 years ago by Thierry Delisle

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.