public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jan Hubicka <hubicka@ucw.cz>
To: Peter Lafreniere <peter@n8pjl.ca>
Cc: GCC <gcc@gcc.gnu.org>
Subject: Re: [GSoC] Introduction and query on LTO object emmission project
Date: Fri, 3 Mar 2023 19:28:44 +0100	[thread overview]
Message-ID: <ZAI8XIwfaGgbl8iJ@kam.mff.cuni.cz> (raw)
In-Reply-To: <Y2fYUPcdSb9I1jsxgvY7M9YPYgTeWkTe3JS4Mx1BHjwCaP6_jrFK6afYNdVad80y6wpCVkvepjsZiKeGtEZktwiES1KXR6queMgqNHNea3k=@n8pjl.ca>

Hello,
> Hi! I've been interested in compiler development for a while, and would love to
> work with any of you as part of GSoC, or even just as a side-project on my own.
> 
> I'm an 18 year-old student going into university next year with a passion for all
> things open source and low level. I consider myself fluent in c, and proficient
> with c++, rust, and x86 assembly, but unfamiliar with practical compiler design.
> I have done some reading on the theoretical aspects of compilers, however.
> 
> While I haven't worked with the GCC community before, I have worked with the linux
> community and have made several small patches there, so I am familiar with both
> email-based workflows and the principles of open-source development. 
> 
> This summer, I'm looking for more experience working on larger projects, as well
> as getting into real compilers.
> 
> Of particular interest to me is the project idea labelled "Bypass assembler when
> generating LTO object files." I see that the project was taken last year, but
> I can find no sign of any changes committed to trunk 
> (`git shortlog --after=2022-01-01 | grep -i -E "lto|assembl(er|y)"` shows nothing
> related to this project) and no sign of any needed change made in the code.
> Is this project still available?

yes, the project is available and Maritn Jambor <mjambor@suse.cz> and me
would be happy to mentor it. Please add me and Martin to CC of any
emails on the proejt.

I think it would be good to start by looking at the original work in
progress patch (linked from the task description, an updated version is
here https://gcc.gnu.org/pipermail/gcc/2022-May/238670.html).   Overall
struture of the LTO optimization is described in paper
https://arxiv.org/abs/1010.2196

One problem is that the object files produced by libiberty/simple-object.c
(which is the low-level API used by the LTO code)
are missing some information (such as the architecture info and symbol
table) and API of the simple object will need to be extended to handle
that.  So I think getting familiar with simple-object.c and the
elf/mach/coff handlers of it would be a good initital step.  It will be
necessary to add API to specify the architecture and symbols in the
symbol table so the resulting object files are recognized by linker.

Second part would be handling of output of dwarf debug information, so
it may make sense to also take a quick look on its documentation.  The
on-disk representation is actually not too hard and it should be
possible to make a direct writer.

Jan
> 
> I'm also willing to work on other projects, ideally in the middle/backend, but
> currently I have only been experimenting with the gcc/[lto,data]-streamer* files.
> If anyone has a small or medium sized project idea, please feel free to let me know.
> 
> 
> I look forward to working with all of you in the future,
> 
> Peter Lafreniere
> <peter@n8pjl.ca>
> 

  reply	other threads:[~2023-03-03 18:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-24 16:02 Peter Lafreniere
2023-03-03 18:28 ` Jan Hubicka [this message]
2023-03-06 16:48   ` David Malcolm

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=ZAI8XIwfaGgbl8iJ@kam.mff.cuni.cz \
    --to=hubicka@ucw.cz \
    --cc=gcc@gcc.gnu.org \
    --cc=peter@n8pjl.ca \
    /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).