From: Hongxu Jia <hongxu.jia@windriver.com>
To: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>,
Joseph Myers <joseph@codesourcery.com>
Cc: <jakub@gcc.gnu.org>, <rguenth@gcc.gnu.org>,
<gcc-patches@gcc.gnu.org>,
<richard.purdie@linuxfoundation.org>
Subject: Re: [PATCH V3]PR other/70268: map one directory name (old) to another (new) in __FILE__
Date: Fri, 18 Mar 2016 09:36:00 -0000 [thread overview]
Message-ID: <56EBCB58.807@windriver.com> (raw)
In-Reply-To: <56EBB6DE.603@windriver.com>
On 03/18/2016 04:05 PM, Hongxu Jia wrote:
>>
>> Please explain why you first alloca() and then strdup the result
>> instead of XNEWVEC
>
BTW, I just refer the implement of -fdebug-prefix-map:
In gcc/final.c
----------------
const char *
remap_debug_filename (const char *filename)
----------------
//Hongxu
> 1. alloca - allocate memory that is automatically freed when the
> function remap_file_filename returns
>
> 2. XNEW - allocate memory for struct file_prefix_map
>
> 3. xstrdup - duplicate a string
>
> //Hongxu
>
>
>>
>> Thanks,
next prev parent reply other threads:[~2016-03-18 9:33 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-17 8:57 [PATCH]PR " Hongxu Jia
2016-03-17 9:54 ` [PATCH V2]PR " Hongxu Jia
2016-03-17 22:47 ` [PATCH]PR " Joseph Myers
2016-03-18 2:30 ` Hongxu Jia
2016-03-18 7:56 ` [PATCH V3]PR " Hongxu Jia
2016-03-18 8:05 ` Bernhard Reutner-Fischer
2016-03-18 8:11 ` Hongxu Jia
2016-03-18 9:36 ` Hongxu Jia [this message]
2016-03-23 7:49 ` Hongxu Jia
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=56EBCB58.807@windriver.com \
--to=hongxu.jia@windriver.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jakub@gcc.gnu.org \
--cc=joseph@codesourcery.com \
--cc=rep.dot.nop@gmail.com \
--cc=rguenth@gcc.gnu.org \
--cc=richard.purdie@linuxfoundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).