[PATCH] [asan] debug_mapping.cc should also pass when the leading digit is hexadecimal.
Daniel.Sanders at imgtec.com
Thu Apr 23 06:51:18 PDT 2015
> -----Original Message-----
> From: Timur Iskhodzhanov [mailto:timurrrr at google.com]
> Sent: 23 April 2015 14:38
> To: Daniel Sanders; kcc at google.com; Sagar Thakur; timurrrr at google.com
> Cc: llvm-commits at cs.uiuc.edu
> Subject: Re: [PATCH] [asan] debug_mapping.cc should also pass when the
> leading digit is hexadecimal.
> Nice catch, I've overlooked that code!
> `SHADOW_SCALE` is currently a constant equal to `3` and it can't be more
> than 8 with the current ASan design, I think?
Now that you mention it, I see there's a 'CHECK(SHADOW_SCALE >= 3 && SHADOW_SCALE <= 7);' a few lines down.
> Probably, the same applies to `SHADOW_GRANULARITY` - it is currently equal
> to 8, can't be more than 256 and I'd argue we should always print them out as
> decimals for readability.
> That's being said, I think the `Printf` line you're referring to should be
> changed to just use `%d`.
> [I suspect this is a side effect of copy-pasting code]
That makes sense to me. I'll upload a patch for those two shortly.
> EMAIL PREFERENCES
More information about the llvm-commits