From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=cdNwOrEm; spf=pass (domain: linaro.org, ip: 209.85.221.67, mailfrom: leif.lindholm@linaro.org) Received: from mail-wr1-f67.google.com (mail-wr1-f67.google.com [209.85.221.67]) by groups.io with SMTP; Wed, 02 Oct 2019 02:13:22 -0700 Received: by mail-wr1-f67.google.com with SMTP id i1so18740285wro.4 for ; Wed, 02 Oct 2019 02:13:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=9IGm6bWQhudnWMPy80FSbqU2oKgS8IqbgfJZM9X7kR8=; b=cdNwOrEmYdN/vuzlonFpUiO0lynULX3X7DvL1f7Gw0kpYOPoZ8GLAATe0uGn/81jVS V4Uou/MRcEYDH4tZCa/Ap+1k2oRjkbDPZcme05S9IlYHRyI1RYXskPvqrzJxfazh081y lq16ReylMOlghXmJBO2xZuPTf7sx9G8LExNiYtXNkCMuUEzklqq1g8je0BdbbJ6uZI4T rmHzODyDjbnXEOKamIKItXu26HpxsksU8stbiXS/cB0jJHSkX1IescNkPrRTicHW3c+Y srxgHjmonj/1B73iZcRqPQ5k2Dvwlr7x8v/uUKngz44bBUvwew4lcwSARS7ri1o1siMV wo+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=9IGm6bWQhudnWMPy80FSbqU2oKgS8IqbgfJZM9X7kR8=; b=VOdLNeahJrWHnESSouH/82G6SaT2Ybu45rIUU1zT3PPjz7erIDFiG3jVKaRTa5cwrT lM6UW2CsjiIedVbNa/K7qHbG2f6YkyIWg2R+XFj1iHsAEE0OA+RI804Y3WQzFHi0su5P VubKU2yvbBWMCzPYSaX4ofdkshmq3EmIhiKHSjKtc67/ww3vVbd8VUeh+LMv/C9zjL8g Wj5TILtyiFhEyDzFd6SBp5I4VDotmS5/0i+SnJ/So6TBbdk+zJacL9+ZP/yzfg2P7LFr JpsA/BSmumZuBGaiwQe89E6/RWWX5wPklSy8G2skoMpbrkuXqsFANhZtnm5Q6i18/kZK X9lA== X-Gm-Message-State: APjAAAW7ygrmqRogEeTmKbwW8FHXojwt8M1M2KWCH31Is0O1EWOwPPAt LzLTXQ8OccfCetAqL1fBWRwvtQ== X-Google-Smtp-Source: APXvYqyUaWJrfQ/qqKpPiB64KHCWNAGzbXV264a0jkiA4y6k5mFMaC9AX3/hndfQ2i9ju8Pg+ZFuUg== X-Received: by 2002:adf:bb0a:: with SMTP id r10mr1904941wrg.13.1570007600292; Wed, 02 Oct 2019 02:13:20 -0700 (PDT) Return-Path: Received: from bivouac.eciton.net (bivouac.eciton.net. [2a00:1098:0:86:1000:23:0:2]) by smtp.gmail.com with ESMTPSA id e15sm1119153wrt.94.2019.10.02.02.13.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Oct 2019 02:13:19 -0700 (PDT) Date: Wed, 2 Oct 2019 10:13:17 +0100 From: "Leif Lindholm" To: "Chang, Abner (HPS SW/FW Technologist)" Cc: "devel@edk2.groups.io" , Philippe =?iso-8859-1?Q?Mathieu-Daud=E9?= Subject: Re: [edk2-devel] [edk2-staging/RISC-V-V2 PATCH v2 09/29] MdePkg/BaseIoLibIntrinsic: RISC-V I/O intrinsic functions. Message-ID: <20191002091317.GZ25504@bivouac.eciton.net> References: <1569198715-31552-1-git-send-email-abner.chang@hpe.com> <1569198715-31552-11-git-send-email-abner.chang@hpe.com> <20190926233928.GL25504@bivouac.eciton.net> <90c04adf-79b1-2d89-1683-c916444126c7@redhat.com> <20191001090705.GQ25504@bivouac.eciton.net> MIME-Version: 1.0 In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Oct 02, 2019 at 01:30:12AM +0000, Chang, Abner (HPS SW/FW Technologist) wrote: > > There should be exactly one variant of IoLib.c. Well, these days we need a > > separate one for ARM/AARCH64 under hw virtualization. > > > > IoLibArm, IoLibEbc and IoLibRiscV have *exactly* the same requirements. > > And now x86 uses NASM regardless of build platform, I think it would make > > sense to move the contents of IoLibGcc and IoLibMsc into assembler. > > That looks weird and doesn't make sense to use Arm code for RISC-V > even the functionality is exactly the same to IoLibRiscV. I will > still keep it as IoLibRiscV.c until there is a generic IoLib for > different arch. This is C code. It is no more weird to use "another architecture's" code than it is to add another file doing exactly the same thing but pretending it is "for" another architecture. And one of those options does not pile up even more code duplication in the tree. But you are welcome to convince some other maintainer of the opposite. / Leif