Hi,
The following c source code abc.c:
#include
int g_val=10;
const char *g_str="abc";
const char *g_str1="c";
int main(void)
{
printf("%s %s: %d\n",g_str,g_str1,g_val);
return 0;
}
When compile with "clang abc.c -o abc" then dump .rodata section:
# readelf -p .rodata abc
String dump of
8 3:54 PM
To: Jian, Xu
Cc: cfe-users@lists.llvm.org
Subject: Re: [cfe-users] how clang merge strings in .rodata section
On Thu, Jul 5, 2018 at 3:18 AM, Jian, Xu via cfe-users
wrote:
> Hi,
>
> The following c source code abc.c:
>
> #include
>
> int g_val=10;
>
> const ch
:hwennb...@google.com>
> [mailto:hwennb...@google.com] On Behalf Of
> Hans Wennborg
> Sent: Friday, July 6, 2018 3:54 PM
> To: Jian, Xu
> Cc: cfe-users@lists.llvm.org<mailto:cfe-users@lists.llvm.org>
> Subject: Re: [cfe-users] how clang merge strings in .rodata secti