Binary Autovectorization
Hi, I am looking at binary auto-vectorization or taking a binary and rewriting it to use SIMD instructions (either statically or dynamically). I was wondering if anyone knew of similar work and could help me with some links. Thank you, Rodrigo Dominguez
RE: Binary Autovectorization
Nathan, Great! This is the kind of work I am interested in. Thank you. Rodrigo > -Original Message- > From: Nathan Froyd [mailto:froy...@codesourcery.com] > Sent: Thursday, January 29, 2009 5:04 PM > To: Rodrigo Dominguez > Cc: gcc@gcc.gnu.org > Subject: Re: Binary Autovectorization > > On Thu, Jan 29, 2009 at 04:46:37PM -0500, Rodrigo Dominguez wrote: > > I am looking at binary auto-vectorization or taking a binary and > rewriting > > it to use SIMD instructions (either statically or dynamically). I was > > wondering if anyone knew of similar work and could help me with some > links. > > Anshuman Dasgupta did some work at Rice University on binary > autovectorization of x86 binaries. See: > > http://www.cs.rice.edu/~keith/pubs/LACSI02.pdf > > His master's thesis might also be available online. > > -Nathan
Inline Assembly Error: suffix or operands invalid for 'shr'
Hi, While debugging a problem with Open64, I ran into a similar problem with GCC. I created the following unit test program: #include int main(void) { uint32_ta = 7; int8_t s = -1; __asm__ ("shrl %1, %0\n\t" : "+r" (a) : "c" (-s) ); return a; } When assembling this program, 'cc1' emits a 'shrl %ecx, %eax' instruction. The 'shr' instruction can only take an 8-bit register as the first operand. The emitted instruction should have been 'shrl %cl, %eax'. Therefore, the compilation fails with a 'suffix or operands invalid for shr' message. I have 2 questions: 1. AFAIK, by default, __asm__ chooses a register according to the size of the operand (int8_t in this case). Is this correct? Where can I find documentation of this? 2. If #1 is true, why does this fail? Thank you, Rodrigo
RE: Inline Assembly Error: suffix or operands invalid for 'shr'
H.J, Thanks for replying but this doesn't answer my question. Shouldn't __asm__ generate the right code without using the %b1 trick? The reason I am asking is I have a 350 line macro which I can't change. Is there any documentation about __asm__ default behavior regarding this issue? Something like an Intel/AMD/AT&T manual explaining this? Thank you, Rodrigo > -Original Message- > From: H.J. Lu [mailto:hjl.to...@gmail.com] > Sent: Tuesday, March 24, 2009 2:09 PM > To: Rodrigo Dominguez > Cc: gcc@gcc.gnu.org > Subject: Re: Inline Assembly Error: suffix or operands invalid for > 'shr' > > On Tue, Mar 24, 2009 at 11:02 AM, Rodrigo Dominguez > wrote: > > Hi, > > > > While debugging a problem with Open64, I ran into a similar problem > with > > GCC. I created the following unit test program: > > > > #include > > > > int main(void) > > { > > uint32_t a = 7; > > int8_t s = -1; > > > > __asm__ ("shrl %1, %0\n\t" > > : "+r" (a) > > : "c" (-s) > > ); > > > > return a; > > } > > > > When assembling this program, 'cc1' emits a 'shrl %ecx, %eax' > instruction. > > The 'shr' instruction can only take an 8-bit register as the first > operand. > > The emitted instruction should have been 'shrl %cl, %eax'. Therefore, > the > > compilation fails with a 'suffix or operands invalid for shr' > message. > > > > Please use > >__asm__ ("shrl %b1, %0\n\t" >: "+r" (a) >: "c" (-s) >); > > -- > H.J.
Contributing to cross-compiling
Hi, I am PhD student in Computer Engineering. I would like to contribute to GCC and at the same time learn more about cross-compilers. I have taken a couple of compiler classes and I can program in C. However, I am not familiar with the GCC internals. Do you have any suggestions on a project related to cross-compiling that I could start with? Perhaps cross-compiling for the XScale/ARM target? Thank you, Rodrigo
RE: Contributing to cross-compiling
Thanks for your suggestions. It seems like the best place to start for someone new to GCC would be the beginners projects off from the GCC Projects webpage (http://gcc.gnu.org/projects/beginner.html). I think I will start from there and then try to move to the cross-compiling area. Thanks again for the links. They were helpful. Rodrigo -Original Message- From: Ian Lance Taylor [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 30, 2008 4:09 PM To: Rodrigo Dominguez Cc: gcc@gcc.gnu.org Subject: Re: Contributing to cross-compiling "Rodrigo Dominguez" <[EMAIL PROTECTED]> writes: > I am PhD student in Computer Engineering. I would like to contribute to GCC > and at the same time learn more about cross-compilers. I have taken a couple > of compiler classes and I can program in C. However, I am not familiar with > the GCC internals. Do you have any suggestions on a project related to > cross-compiling that I could start with? Perhaps cross-compiling for the > XScale/ARM target? Thanks for your interest. There are a number of general projects for gcc. Google's Summer of Code is not running right now, but the wiki page for it points to a number of lists of open projects: http://gcc.gnu.org/wiki/SummerOfCode Most of those are not specifically related to cross-compiling, but of course improvements to the general compiler will improve all targets. The ARM target is in pretty good shape in general. However, I do know that the code size is not as good as that generated by ARM's proprietary compiler. So that would an area to investigate. Also a quick bugzilla search for ARM turns up a number of open bug reports. I haven't looked at these at all so I don't know how relevant they are. http://gcc.gnu.org/bugzilla/buglist.cgi?query_format=advanced&short_desc_typ e=allwordssubstr&short_desc=ARM&known_to_fail_type=allwordssubstr&known_to_w ork_type=allwordssubstr&long_desc_type=substring&long_desc=&bug_file_loc_typ e=allwordssubstr&bug_file_loc=&gcchost_type=allwordssubstr&gcchost=&gcctarge t_type=allwordssubstr&gcctarget=&gccbuild_type=allwordssubstr&gccbuild=&keyw ords_type=allwords&keywords=&bug_status=UNCONFIRMED&bug_status=NEW&bug_statu s=ASSIGNED&bug_status=SUSPENDED&bug_status=WAITING&bug_status=REOPENED&email assigned_to1=1&emailtype1=substring&email1=&emailassigned_to2=1&emailreporte r2=1&emailcc2=1&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes =&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Reuse+same+sor t+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0= Hope this helps. Ian
Make insn-recog.c use a byte-coded DFA
Hi, I am a new contributor to GCC. I am interested in the following project from the beginners webpage: "Make insn-recog.c use a byte-coded DFA" I would like to know what's the status of this item? Is this still an open project? Doing a quick search on the mailing list archives I was only able to find one reference to this project: http://gcc.gnu.org/ml/gcc/2005-08/msg00667.html Thank you, Rodrigo Dominguez
Replying to a mailing list thread
Hi, This sounds like a trivial question but I wasn't able to find any information on the Mailing List webpage: How do you reply to a thread in the mailing lists? The only way I can think of is sending an email with the same subject and copy/paste the thread into the email body. Will this work? Will my email be added to the active thread (I don't want the system to create a new thread)? Is there a better way to do it beside copy/pasting? Thanks for your help. Rodrigo
Re: Replying to a mailing list thread
On Sat, 2 Feb 2008, NightStrike wrote: > On 2/2/08, Jonathan Wakely <[EMAIL PROTECTED]> wrote: > > On 02/02/2008, Rodrigo Dominguez wrote: > > > > > > How do you reply to a thread in the mailing lists? The only way I can > > > think of is sending an email with the same subject and copy/paste the > > > thread into the email body. Will this work? > > > > No. Just use the "reply" function of your mail program. If you send a > > new email with the same subject it probably won't be considered part > > of the same thread. If you reply to a previous mail (and you don't > > have a broken email program) it will just work, the details are > > off-topic here. > > > > > Will my email be added to the > > > active thread (I don't want the system to create a new thread)? Is there a > > > better way to do it beside copy/pasting? > > > > Your email program should be able to include the content of the mail > > you're replying to. If it can't, get a new email program. > > > > Jon > > > I'm assuming that he meant an older message for which his only copy is > in the mailing list archives. In that case, he would have to use the > mailer daemon message request feature. > Exactly! What do you mean by the "mailer daemon message request feature" and how do I use it? Rodrigo
Re: Replying to a mailing list thread
On Sat, 2 Feb 2008, NightStrike wrote: > On 2/2/08, Jonathan Wakely <[EMAIL PROTECTED]> wrote: > > On 02/02/2008, Rodrigo Dominguez <[EMAIL PROTECTED]> wrote: > > > > > > On Sat, 2 Feb 2008, NightStrike wrote: > > > > > > > On 2/2/08, Jonathan Wakely <[EMAIL PROTECTED]> wrote: > > > > > On 02/02/2008, Rodrigo Dominguez wrote: > > > > > > > > > > > > How do you reply to a thread in the mailing lists? The only way I > > > > > > can > > > > > > think of is sending an email with the same subject and copy/paste > > > > > > the > > > > > > thread into the email body. Will this work? > > > > > > > > > > No. Just use the "reply" function of your mail program. If you send a > > > > > new email with the same subject it probably won't be considered part > > > > > of the same thread. If you reply to a previous mail (and you don't > > > > > have a broken email program) it will just work, the details are > > > > > off-topic here. > > > > > > > > > > > Will my email be added to the > > > > > > active thread (I don't want the system to create a new thread)? Is > > > > > > there a > > > > > > better way to do it beside copy/pasting? > > > > > > > > > > Your email program should be able to include the content of the mail > > > > > you're replying to. If it can't, get a new email program. > > > > > > > > > > Jon > > > > > > > > > I'm assuming that he meant an older message for which his only copy is > > > > in the mailing list archives. In that case, he would have to use the > > > > mailer daemon message request feature. > > > > > > > > > > Exactly! > > > > Aaaah, I see. > > > > > What do you mean by the "mailer daemon message request feature" and how do > > > I use it? > > > > The WELCOME mail you get after subscribng to any of the lists > > describes the administrative commands for the list, which allow you to > > fetch old messages. Do I need to subscribe to the mailing list in order to run this commands? I don't want to start getting tons of emails when anyone posts to the list. There should be a way to do this without subscribing. Otherwise, what if tomorrow I want to reply to a thread from a different list? Would I have to subscribe to that list too??? > > > > Jon > > > > I thought this, too, but I just checked (having recently subscribed, I > still had the welcome email). The email doesn't contain any of the > instructions I thought it did. Instead, you have to send a message to > [EMAIL PROTECTED] with "help" in the body to receive the > email with all the instructions that typically come in the welcome > email. > I tried sending an email to [EMAIL PROTECTED] but the help message doesn't say anything about how to reply to an specific thread. It has information about administring your Bug-coreutils account. Rodrigo
Structured Exception Handling in gcc
Hi, I am looking for information on how GCC implements Structured Exception Handling (try/catch) in C++ programs. I would really appreciate any pointers that helped me understand the internals. Thank you, Rodrigo