[libre-riscv-dev] New Person

Daniel Benusovich flyingmonkeys1996 at gmail.com
Fri Oct 12 07:07:49 BST 2018


I edited the spike.cc found in the spike-sv riscv-isa-sim version and added
ye old verification (a printf) to see if I was running the correct spike
version and viola output! I was able to run the commands directly via spike
after running "make clean" on riscv-tools/riscv-isa-sim/build and "make
install" on riscv-isa-sim/build (the lbre version). Flipping the process
would not cause the printout to me confirming that something good is
happening. I did not discover where the debug output you spoke of was sent
to; if it goes to the console then I am still very much lost! If it does
not go to the console do let me know where it is stored so I can search for
it.

If this is all correct do tell me what to fuss over next. I will happily
add to the installation procedure docs so that my mother could try and
install this as well if i did it correctly haha.

On Wed, Oct 10, 2018 at 11:49 PM Daniel Benusovich <
flyingmonkeys1996 at gmail.com> wrote:

> If I clone the risv-isa-sim repo from libre into a seperate directory,
> seperate from the riscv-tools repo, and run make install within
> risv-isa-sim from libre will the spike executable default to the
> risv-isa-sim libre version or the version provided within riscv-tools?
>
> Both compiled correctly and this seems to be the last step. However, I am
> not certain the correct sim is being called as both simulators have been
> built. I called 'make clean" on the riscv-tools/riscv-isa-sim/build while
> leaving the risv-isa-sim libre version build folder alone and was able to
> run a hello world via the spike simulator. Would this be a sign of success?
>
>
> On Tue, Oct 9, 2018 at 10:58 PM Daniel Benusovich <
> flyingmonkeys1996 at gmail.com> wrote:
>
>> I was able to setup the tools (using the master branch), the libre
>> repositories, and complete the instructions found here:
>> https://libre-riscv.org/3d_gpu/spike_sv/
>>
>> Thankfully no need for any additional tools to set everything up from
>> riscv-tools for elf-gcc-7.2.0 or elf-gcc, just good old build scripts
>> provided by the repository.
>>
>> I can confirm that both the RISCV and the PATH variables must be set
>> prior to running the unit tests in riscv-tests. Are the resulting output
>> files expected to be empty? A flurry of the buggers were generated but they
>> are empty; though my guess is these tests exist to verify that all the
>> includes and whatnot were generated properly.
>>
>> In addition I was able to compile and run a Hello World program using the
>> elf-gcc-7.2.0/elf-gcc and spike simulator respectively. I am pretty sure
>> the simulator is using the stock riscv-isa-sim and not the augmented
>> version provided by libre. A task for tomorrow indeed.
>>
>> It would be good to move the setting of the RISCV and PATH variables to
>> the top of the installation procedure. Would've saved a bit of a headache.
>> Also a link to the riscv-tools would've made things a tad bit easier:
>> https://github.com/riscv/riscv-tools and specification on which branch
>> should or could be used (master in my case).
>>
>> I will try messing around reinstalling everything again tomorrow and have
>> a more comprehensive guide on how it should work including trying to use
>> the libre augmented spike simulator rather than the riscv-tools version.
>>
>> Hope you are having a good one!
>>
>>
>>
>> On Mon, Oct 8, 2018 at 10:22 PM Daniel Benusovich <
>> flyingmonkeys1996 at gmail.com> wrote:
>>
>>> Yes that clears up my questions thank you!
>>>
>>> I look forward to being the second person in the world (maybe) to make
>>> something work haha.
>>>
>>> I will keep you posted on any progress or roadblocks that appear. Thank
>>> you for your time and patience!
>>>
>>> - Daniel B.
>>>
>>> On Sun, Oct 7, 2018 at 11:39 PM lkcl <lkcl at libre-riscv.org> wrote:
>>>
>>>> On Mon, Oct 8, 2018 at 4:43 AM Daniel Benusovich
>>>> <flyingmonkeys1996 at gmail.com> wrote:
>>>> >
>>>> > I have a few questions on the environment.
>>>> >
>>>> > riscv-tools repository has a version of Spike. Is the same one
>>>> contained
>>>> > in the libre-riscv repository a fork of that one?
>>>>
>>>>  yes it is.  so, if compiling the standard riscv-tools succeeds (there
>>>> are some automated build scripts to do so), it would then just be a
>>>> matter of "git checkout -b sv"
>>>>
>>>> >  I noticed it does have the libre-riscv repository version has a
>>>> > description stating it is an augmented version but I just want to be
>>>> sure.
>>>>
>>>>  yep, you're right.
>>>>
>>>> > What you asked me to document is the process of creating a
>>>> > development environment that one can use to compile and
>>>> > then run a sample program using the simulator correct?
>>>>
>>>>  the unit tests - riscv-tests/isa with "make run", yes.
>>>>
>>>> > The instructions on the page detail vaguely how to set it up but
>>>> > not how to verify the installation or compile/run any programs
>>>> > which I am guessing is the missing documentation that needs to be
>>>> done.
>>>>
>>>>  yup :)  or, just the very fact that you're asking the questions means
>>>> i will put in some notes (like i have now), as that illustrates to me
>>>> the things that i know which haven't been recorded.
>>>>
>>>> > Also are the unit tests that need work regarding the Spike simulator
>>>> > or another component of the project?
>>>>
>>>>  ok so the riscv-tests unit tests are generic, they can be used
>>>> anywhere, for any purpose, to test any simulator or any real hardware.
>>>> it would be possible to run them on an FPGA, under verilator:
>>>> anything.
>>>>
>>>>  so, therefore, i *happen* to be using them to bootstrap spike-sv up
>>>> to a working implementation, making sure that as i add new
>>>> functionality i don't break the old stuff.
>>>>
>>>>  once that's up and running, and spike-sv is stable, i can look at
>>>> other areas, and perhaps we could ask jacob if he needs help
>>>> documenting what he's doing.
>>>>
>>>>  once you have a working dev-environment and "make run" on the isa
>>>> tests passes (which will be worth celebrating on its own, you'd be i
>>>> think only the second person in the world to do so), we can discuss
>>>> further what you'd like to do.
>>>>
>>>> > If it is the Spike sim unit tests need work is it the tests in the
>>>> riscv-tools repository or the libre-riscv repository?
>>>>
>>>>  the two libre-riscv repositories riscv-isa-sim and riscv-tests are
>>>> forks of two of the riscv-tools repositories.  adding sv unit tests to
>>>> the standard riscv-tools repository would not be useful to do, as the
>>>> standard riscv-tools repository knows absolutely nothing about sv.
>>>> hence why i have forked them.
>>>>
>>>> hope that clarifies?
>>>>
>>>> l.
>>>>
>>>


More information about the libre-riscv-dev mailing list