- May 19, 2021
-
-
Andrew Waterman authored
-
- May 18, 2021
-
-
Andrew Waterman authored
-
Andrew Waterman authored
-
- May 08, 2021
-
-
Andrew Waterman authored
Resolves #216
-
Saleem Abdulrasool authored
Use of asm aliased register variables in local scope can only be used for extended assembly parameters. This changes the few instances of this in the floating point emulation to use the GNU extended assembly syntax to access the `tp` register. This ensures that we do not rely on undefined behaviour. This was uncovered when building the Proxy kernel with clang and LLVM.
-
Saleem Abdulrasool authored
The use of `asm` for register aliasing is supported in two different contexts: - local variables (including GNU expression statements) where it may only be used for specifying registers for input and output operands to extended `asm` syntax. c.f. https://gcc.gnu.org/onlinedocs/gcc/Local-Register-Variables.html#Local-Register-Variables - global variables where it may be used to observe the contents of a register. c.f. https://gcc.gnu.org/onlinedocs/gcc/Global-Register-Variables.html#Global-Register-Variables The two options here is to either to hoist the variable out into a global variable, but then it should not be in a header due to fears of ODR in case the optimizer does not inline it away, and thus becomes a bit more tricky. The alternative that this change actually adopts is to explicitly use a move to copy the value out via the GNU extended assembly syntax. With this change, it is now possible to build the Proxy Kernel completely with clang/LLVM and link with LLD. The generated kernel also runs under SPIKE and behaves as expected in a simple smoke test (without any executable prints the expected message, and runs a trivial RVV example).
-
- May 07, 2021
-
-
Saleem Abdulrasool authored
This is an equivalent rewrite of the existing code. When building with gas, the `bltu` would implicitly get relaxed to the `bgeu` + `j`. This relaxation is required as the `init_other_hart` is not guaranteed to be addressable in 12-bits. When building with the LLVM IAS instead of gas we fail to link as the branch is not relaxed. This change enables LLVM to build and link this code with the LLVM IAS and lld.
-
- May 06, 2021
-
-
Saleem Abdulrasool authored
The LLVM IAS currently does not support the older spelling for the CSR. Update the references to the modern name.
-
Saleem Abdulrasool authored
The LLVM IAS does not support the older name for the `mtval` CSR. This updates the name to the current spelling, which is required to build with the LLVM IAS. This remains compatible with binutils as well.
-
Saleem Abdulrasool authored
This replaces use of the old `sbadaddr` CSR name with the current `stval` name. The old spelling is not supported by the LLVM IAS, however, the modern spelling is supported by both LLVM and binutils.
-
- Apr 28, 2021
-
-
Christoph Müllner authored
Using recent compilers we get the following error message: ../pk/pk.c: In function 'run_loaded_program.constprop': ../pk/pk.c:177:3: error: both arguments to '__builtin___clear_cache' must be pointers 177 | __clear_cache(0, 0); | ^~~~~~~~~~~~~~~~~~~ Let's use the existing function __riscv_flush_icache(), give it a header with a prototype and use it to emits the FENCE.I instruction directly. See #239 Suggested-by:Andrew Waterman <andrew@sifive.com> Signed-off-by:
Christoph Muellner <cmuellner@linux.com>
-
- Apr 06, 2021
-
-
gsomlo authored
The upstream LiteX project defaults to "litex,liteuart" as the value for the "compatible" property of the UART DT node, so let's add it to the current list of accepted strings. Signed-off-by:Gabriel Somlo <gsomlo@gmail.com>
-
- Mar 30, 2021
-
-
Andrew Waterman authored
-
Andrew Waterman authored
This assumes that stval is populated with the opcode on illegal instruction exceptions. But since we're only using the opcode for error reporting, it's OK if this assumption is violated.
-
Andrew Waterman authored
-
Andrew Waterman authored
-
Andrew Waterman authored
-
- Mar 27, 2021
-
-
Andrew Waterman authored
-
Andrew Waterman authored
-
- Mar 26, 2021
-
-
Andrew Waterman authored
-
Andrew Waterman authored
Previously, the pk would always run from virtual address MEM_START. Instead, remap it into the negative virtual addresses, allowing user processes to expand beyond MEM_START.
-
Andrew Waterman authored
-
Andrew Waterman authored
Return the old brk if mmap fails, rather than just asserting out
-
Andrew Waterman authored
Estimate available memory and return -1 from mmap if not enough is available, rather than assert-failing.
-
Andrew Waterman authored
This will improve flexibility going forward.
-
Andrew Waterman authored
Enforced with sstatus.SUM.
-
huaixv authored
-
- Dec 16, 2020
-
-
gsomlo authored
Tested using the RocketChip CPU option. (see https://github.com/enjoy-digital/litex ) Signed-off-by:
Gabriel Somlo <gsomlo@gmail.com>
-
- Nov 30, 2020
-
-
Andrew Waterman authored
-
Marcus Comstedt authored
-
- Nov 24, 2020
-
-
Andrew Waterman authored
-
Marcus Comstedt authored
-
- Nov 17, 2020
-
-
Andrew Waterman authored
Remove use of copy_stat() from sys_fstatat
-
Marcus Comstedt authored
The system call should return the stat struct in kernel format, not libc format.
-
- Nov 13, 2020
-
-
Andrew Waterman authored
Big endian
-
- Nov 12, 2020
-
-
Marcus Comstedt authored
The linux kernel pushes argc as an int, not an uintptr_t. (The offset to the next element is still sizeof(uintptr_t).)
-
Marcus Comstedt authored
-
- Nov 01, 2020
-
-
Yan authored
* add device tree in elf, using --with-dts to add the absolute path of device tree * Disable device tree filter * Remove *.dtb dependence, when the --with-dts option is not used
-
- Oct 31, 2020
-
-
Andrew Waterman authored
This reverts commit a161e6f3. Resolves #218
-
- Oct 30, 2020
-
-
Yan authored
* add device tree in elf, using --with-dts to add the absolute path of device tree * Disable device tree filter
-