From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg1-x532.google.com (mail-pg1-x532.google.com [IPv6:2607:f8b0:4864:20::532]) by sourceware.org (Postfix) with ESMTPS id 05BA03858D28 for ; Mon, 1 Apr 2024 17:45:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 05BA03858D28 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=uci.edu Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=uci.edu ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 05BA03858D28 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::532 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1711993533; cv=none; b=jkNIUoZkFSciJsXK63xzfaWL12zo6BoZP0lCgPZtDLMe/Sg9dh5yqCh2qNpNoAJhhGauOPk0dhg3rT2nEptIB5pkgaQTBJTDqZ7RWpvc4TaoTMhuUgxJq+gJtC0CWiO27yDTsraVqnZ8gsEsEApUbnkm/vT4Yb2LJTXvUht6YvA= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1711993533; c=relaxed/simple; bh=8yjBwxIf4g9HLYZQ7dMOHL9Vp3KuzxmjhUPb4xOdGik=; h=DKIM-Signature:MIME-Version:From:Date:Message-ID:Subject:To; b=aFzQWJN0AGd+8t0WFOyYCzGgwonLaweE34uVhHrhyWMHbnp73sblBUZWX6D2KvI//2i4LaSmyPwvl+yJZ8x1P+znCqfMaIGNBmexdrxemSw1nyrG5+zSRzREw3RvPKBPfUkUG6J23DEuvTCL128pQAj+Kk0YXU5INapEyNFk8qc= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-pg1-x532.google.com with SMTP id 41be03b00d2f7-5cddc5455aeso2500208a12.1 for ; Mon, 01 Apr 2024 10:45:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=uci.edu; s=google; t=1711993529; x=1712598329; darn=gcc.gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=ulaprGeYZSN3LOx5miQ2u5JeiVlLz40N/FOuweP1fy8=; b=o3DmyG3//HiIed5KW8te9AqQmBFRuKQIpKaNtAS/X2JCBzC1ES7Dzqdh78XrXxAdRW 7Yk0B7kO2ZUkKhxJuDqbOwKcsuWHXFPQue5cJlicLTa13AZEiHlE2IGkoeE2o9KtAbcT MF3TqxWWDr0YCvy8LhUIvL7bzG+kC+vcfxpOw3n1BE14bG+M2zp3uX121NUyJcgz4f81 9WgP7rEkbILSiWTX+8oJmdDsKzd+kJ1nujJZkbuBZimpxKmHp2ArzVfU/7+NFw7+QG+5 m3bP78taEHCcNZ3lRi5VpXz6hWQC3hrEVif33p2oe3DHO3ScvoR/AuwLRGfpmHrjGdIB 3R2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711993529; x=1712598329; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ulaprGeYZSN3LOx5miQ2u5JeiVlLz40N/FOuweP1fy8=; b=KBppc+EDhlTMvJo7vYtZZCsKhDeddib0IXp31gJNMf5Qcq7GaixmM9NUGSihT5tbsL tpqlGKqZG0ZliAdAWruv1tfRvZTA4HT73x6YYJCZxPoRjDiGE2yEswWmVRhXlN6YGQ4x gahdZCfGFUTTuwnZyU/EExjzKN+Et/8lcWfSsWDAyZQZXIeTIEzTskEOhK1mB1we8aBt RKqEzwYDwAGzdNAOfXSO1oruVWkt2FOJUXYvm1vge0Ih8ZHgVmfyGu+P5+xs4U9w9IOp 5Gu5cBAdZ1Fv23PmsnJYgfTQ/oFEzMRDHFwu/oWX4Hj1XAS3PuA1b8q2OBfLY3ds7rk3 xWRg== X-Gm-Message-State: AOJu0YwBwRROQHouV2V8jlKWv0bdnD5X1jSFWofosNCryHdAENOh8Oeh tV8LS3VuyDNb+pq5QzmMCltlGytwqvPSbv5wzxXbSxXOtrPkE3c3So14M2nVS5fUbrYtcC9LIqG UnBPDS2IqgtUni+nwUQIOHuZf/CKVrsQUL9GzpvvXdnk67MC9 X-Google-Smtp-Source: AGHT+IFqg7UGg5wJGmrpGMb9r3B4q0JTtocI3lyuXYiTfRQEzLo03sWR3zl6s0d6bgEzY6J2UVQFyFQvRG1WvEdTai0= X-Received: by 2002:a17:90a:6b02:b0:2a2:1eb3:6c6e with SMTP id v2-20020a17090a6b0200b002a21eb36c6emr5323681pjj.28.1711993528816; Mon, 01 Apr 2024 10:45:28 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Soumya Ranjan Date: Mon, 1 Apr 2024 10:45:17 -0700 Message-ID: Subject: Re: Initial draft of GSOC proposal - Offloading to a separate process on the same host. To: Martin Jambor Cc: gcc@gcc.gnu.org, tschwinge@baylibre.com Content-Type: multipart/alternative; boundary="00000000000024adf606150c8e95" X-Spam-Status: No, score=-1.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --00000000000024adf606150c8e95 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thank you Martin! I've taken your advice into account and I've uploaded my proposal. On Sat, Mar 30, 2024 at 1:49=E2=80=AFPM Martin Jambor wro= te: > Hello, > > On Wed, Mar 27 2024, Soumya Ranjan wrote: > > Hello! > > Thanks for your response Martin! > > Sorry for the late response, I've been researching the project, going > over > > the source code and preparing the proposal. After a lot of thought, I've > > decided to go with the "Offloading to a separate process on the same > host" > > project, mostly because I feel like I've reasonable background on this > > project, as I've worked on OpenMP, GPU Programming and have done > coursework > > on compilers and operating systems. Yes, I am no longer a student. I > > recently graduated from the University of California, Irvine with a > > master's degree in Computer Engineering (About 3 months back) and I've > > recently joined Qualcomm as a firmware engineer. I realized that I have= a > > lot of free time, that I mostly spend playing video games, and I've > always > > wanted to get into open source development, so I thought this would be a > > good opportunity, given how much I use gcc for everything. > > > > This sounds great. > > First, please note that timing of the GSoC contributor application > deadline (on the upcoming Tuesday) is a bit unfortunate because of > Easter, many involved mentors have a long weekend (public holiday on > Friday or Monday or, like me, both). So please even if you do not > receive any feedback, make sure to apply - and don't leave it until the > last day. IIUC a proposal can be always updated later. > > I'll have to admit that I read your proposal only quickly and it makes > sense. I'd just like to point out that the VGPU part is really a second > (though perhaps much larger and interesting) part of the project, the > first part would be to simulate a CPU-like accelerator with a separate > memory. But most of this work would be necessary for VGPU part too. > What is more, the VGPU part is likely to be hard, so if your time > constraints allow it and doing both is your goal, I'd suggest to apply > for an 350-hour (large) project. > > I'll see if I can cough out any more feedback in time but as I wrote > above, generally it is good and don't wait - t least not with the > initial application. > > Good luck! > > Martin > > > > Why specifically this project - > > OpenMP's support for offloading to physical GPUs broadens the horizon f= or > > high-performance computing applications, the complexity of setting up > such > > environments and the lack of adequate tooling for development and > debugging > > can hinder productivity. The VGPU project directly addresses these > > challenges by providing a developer-friendly offloading target that > > emulates GPU execution on the host CPU, bridging the existing tooling g= ap > > and significantly enhancing developer productivity in the realm of > parallel > > computing. > > > > Anyway, getting into the details of the project, from my understanding, > the > > goals are - > > 1) To implement a virtual GPU (VGPU) environment that mirrors physical > GPU > > architecture including support for different levels of parallelism (war= p, > > thread block, etc.). > > 2) To enable the VGPU to serve as an offload target within the > LLVM/OpenMP > > framework. This includes adding a host-ISA offloaded code generation mo= de > > that allows the compilation of OpenMP applications using GPU-specific > paths > > and runtimes, facilitating a more accurate emulation of GPU environment= s. > > 3) To implement a plugin for libgomp that communicates with the libgomp > > offloading machinery to manage the execution of offloaded code in a new > > process, simulating the behavior of actual GPU devices. > > 4) To optimize the VGPU to ensure that OpenMP applications executed on = it > > incur minimal performance overhead compared to native host execution, > > thereby making it a viable option for development and testing purposes. > > > > Here's a rough timeline (Based on the timeline on the gsoc website) - > > Pre-coding (Until May 27) - > > 1) Setting up a development environment including LLVM/OpenMP and > necessary > > debugging tools. > > 2) Conducting thorough literature review on existing GPU simulation > > techniques and OpenMP offloading mechanisms. > > > > Week 1-3: Initial Infrastructure > > 1) Design VGPU architecture (simulate gpu parallel execution models > (warps, > > blocks) and memory hierarchy (global, shared, private)) > > 2) Implement the core vgpu infrastructure, like basic memory management. > > > > Week 4-6: Integration with LLVM/OpenMP and Host-ISA Offload Mode > > 1) Develop LLVM IR generation for VGPU target, thereby ensuring openMP > > directives can be compiled into vgpu-compatible code. > > 2) Add a new mode in the LLVM/OpenMP framework for generating offloaded > > code specifically for the VGPU target. > > 3) Get simple openMP applications to compile and execute on the VGPU. > > > > By Midterm evaluation, hopefully should have basic openmp applications > > offloaded on the VGPU. > > > > Week 7-9: Extending functionality and Implementing libgomp Plugin > > 1) Extend VGPU to support more functionality like loops, sections, > parallel > > blocks. > > 2) Implement a plug-in for libgomp that interfaces with its offloading > > machinery. > > 3) Maybe look to integrate with debugging tools, so users can step > through > > offloaded regions and profile code. > > > > Week 10-12: Evaluation and Final Submission > > 1) Benchmark against physical GPU's to evaluate the VGPU's performance. > > 2) Prepare a final project report documenting the development process, > > challenges, results and future work. > > > > I know this is a pretty high-level description, but I will try my best = to > > stick to this. This submission is mainly to go over the content. I would > > appreciate any feedback I can get, and will make sure to submit a more > > detailed description on my final submission. Awaiting your feedback. > > Thanks, > > Soumya Ranjan > --00000000000024adf606150c8e95--