-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deploy kvakil/venus to github.com/kvakil/venus.git:gh-pages
- Loading branch information
0 parents
commit 7ef97ee
Showing
5 changed files
with
19 additions
and
0 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<!DOCTYPE html><html><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><title>venus</title><link rel="stylesheet" type="text/css" href="css/venus.css"></head><body><div class="tabs is-boxed is-centered"><ul><li id="editor-tab" class="is-active"><a onclick="driver.openEditor()">Editor</a></li><li id="simulator-tab"><a onclick="codeMirror.save(); driver.openSimulator()">Simulator</a></li></ul></div><div class="container is-fluid"><section class="section" id="editor-tab-view"><div class="field"><div class="control"><textarea class="textarea is-primary is-medium" placeholder="type RISC-V assembly here" id="asm-editor"></textarea></div></div></section></div><section class="section" id="simulator-tab-view"><div class="tile is-ancestor"><div class="tile is-vertical is-8"><div class="tile"><div class="tile is-parent"><article class="tile is-child is-primary" id="simulator-controls-container"><div class="field is-grouped is-grouped-centered"><div class="control"><button id="simulator-run" class="button is-primary" onclick="driver.run()">Run</button></div><div class="control"><button id="simulator-step" class="button" onclick="driver.step()">Step</button></div><div class="control"><button id="simulator-undo" class="button" onclick="driver.undo()">Prev</button></div><div class="control"><button id="simulator-reset" class="button" onclick="driver.reset()">Reset</button></div></div></article></div></div><div class="tile"><div class="tile is-parent"><article class="tile is-child is-primary" id="program-listing-container"><table id="program-listing" class="table"><colgroup><col id="mc-column"><col id="bc-column"><col id="oc-column"></colgroup><thead><tr><th>Machine Code</th><th>Basic Code</th><th>Original Code</th></tr></thead><tbody id="program-listing-body"></tbody></table></article></div></div><div class="tile is-parent"><article class="tile is-child"><textarea id="console-output" class="textarea" placeholder="console output" readonly></textarea></article></div></div><div class="tile is-ancestor"><div class="tile is-vertical"><div class="tile is-parent"><article class="tile is-child" id="sidebar-listings-container"><nav class="panel"><p class="panel-tabs"><a id="register-tab" class="is-active" onclick="driver.openRegisterTab()">Registers</a> <a id="memory-tab" onclick="driver.openMemoryTab()">Memory</a></p><div id="register-tab-view"><div id="reg-0" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-0-val">zero</label></div><div class="field-body is-expanded"><input id="reg-0-val" class="input is-small" onblur="driver.saveRegister(this, 0)" spellcheck="false"></div></div></div><div id="reg-1" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-1-val">ra (x1)</label></div><div class="field-body is-expanded"><input id="reg-1-val" class="input is-small" onblur="driver.saveRegister(this, 1)" spellcheck="false"></div></div></div><div id="reg-2" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-2-val">sp (x2)</label></div><div class="field-body is-expanded"><input id="reg-2-val" class="input is-small" onblur="driver.saveRegister(this, 2)" spellcheck="false"></div></div></div><div id="reg-3" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-3-val">gp (x3)</label></div><div class="field-body is-expanded"><input id="reg-3-val" class="input is-small" onblur="driver.saveRegister(this, 3)" spellcheck="false"></div></div></div><div id="reg-4" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-4-val">tp (x4)</label></div><div class="field-body is-expanded"><input id="reg-4-val" class="input is-small" onblur="driver.saveRegister(this, 4)" spellcheck="false"></div></div></div><div id="reg-5" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-5-val">t0 (x5)</label></div><div class="field-body is-expanded"><input id="reg-5-val" class="input is-small" onblur="driver.saveRegister(this, 5)" spellcheck="false"></div></div></div><div id="reg-6" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-6-val">t1 (x6)</label></div><div class="field-body is-expanded"><input id="reg-6-val" class="input is-small" onblur="driver.saveRegister(this, 6)" spellcheck="false"></div></div></div><div id="reg-7" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-7-val">t2 (x7)</label></div><div class="field-body is-expanded"><input id="reg-7-val" class="input is-small" onblur="driver.saveRegister(this, 7)" spellcheck="false"></div></div></div><div id="reg-8" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-8-val">s0 (x8)</label></div><div class="field-body is-expanded"><input id="reg-8-val" class="input is-small" onblur="driver.saveRegister(this, 8)" spellcheck="false"></div></div></div><div id="reg-9" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-9-val">s1 (x9)</label></div><div class="field-body is-expanded"><input id="reg-9-val" class="input is-small" onblur="driver.saveRegister(this, 9)" spellcheck="false"></div></div></div><div id="reg-10" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-10-val">a0 (x10)</label></div><div class="field-body is-expanded"><input id="reg-10-val" class="input is-small" onblur="driver.saveRegister(this, 10)" spellcheck="false"></div></div></div><div id="reg-11" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-11-val">a1 (x11)</label></div><div class="field-body is-expanded"><input id="reg-11-val" class="input is-small" onblur="driver.saveRegister(this, 11)" spellcheck="false"></div></div></div><div id="reg-12" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-12-val">a2 (x12)</label></div><div class="field-body is-expanded"><input id="reg-12-val" class="input is-small" onblur="driver.saveRegister(this, 12)" spellcheck="false"></div></div></div><div id="reg-13" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-13-val">a3 (x13)</label></div><div class="field-body is-expanded"><input id="reg-13-val" class="input is-small" onblur="driver.saveRegister(this, 13)" spellcheck="false"></div></div></div><div id="reg-14" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-14-val">a4 (x14)</label></div><div class="field-body is-expanded"><input id="reg-14-val" class="input is-small" onblur="driver.saveRegister(this, 14)" spellcheck="false"></div></div></div><div id="reg-15" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-15-val">a5 (x15)</label></div><div class="field-body is-expanded"><input id="reg-15-val" class="input is-small" onblur="driver.saveRegister(this, 15)" spellcheck="false"></div></div></div><div id="reg-16" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-16-val">a6 (x16)</label></div><div class="field-body is-expanded"><input id="reg-16-val" class="input is-small" onblur="driver.saveRegister(this, 16)" spellcheck="false"></div></div></div><div id="reg-17" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-17-val">a7 (x17)</label></div><div class="field-body is-expanded"><input id="reg-17-val" class="input is-small" onblur="driver.saveRegister(this, 17)" spellcheck="false"></div></div></div><div id="reg-18" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-18-val">s2 (x18)</label></div><div class="field-body is-expanded"><input id="reg-18-val" class="input is-small" onblur="driver.saveRegister(this, 18)" spellcheck="false"></div></div></div><div id="reg-19" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-19-val">s3 (x19)</label></div><div class="field-body is-expanded"><input id="reg-19-val" class="input is-small" onblur="driver.saveRegister(this, 19)" spellcheck="false"></div></div></div><div id="reg-20" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-20-val">s4 (x20)</label></div><div class="field-body is-expanded"><input id="reg-20-val" class="input is-small" onblur="driver.saveRegister(this, 20)" spellcheck="false"></div></div></div><div id="reg-21" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-21-val">s5 (x21)</label></div><div class="field-body is-expanded"><input id="reg-21-val" class="input is-small" onblur="driver.saveRegister(this, 21)" spellcheck="false"></div></div></div><div id="reg-22" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-22-val">s6 (x22)</label></div><div class="field-body is-expanded"><input id="reg-22-val" class="input is-small" onblur="driver.saveRegister(this, 22)" spellcheck="false"></div></div></div><div id="reg-23" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-23-val">s7 (x23)</label></div><div class="field-body is-expanded"><input id="reg-23-val" class="input is-small" onblur="driver.saveRegister(this, 23)" spellcheck="false"></div></div></div><div id="reg-24" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-24-val">s8 (x24)</label></div><div class="field-body is-expanded"><input id="reg-24-val" class="input is-small" onblur="driver.saveRegister(this, 24)" spellcheck="false"></div></div></div><div id="reg-25" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-25-val">s9 (x25)</label></div><div class="field-body is-expanded"><input id="reg-25-val" class="input is-small" onblur="driver.saveRegister(this, 25)" spellcheck="false"></div></div></div><div id="reg-26" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-26-val">s10 (x26)</label></div><div class="field-body is-expanded"><input id="reg-26-val" class="input is-small" onblur="driver.saveRegister(this, 26)" spellcheck="false"></div></div></div><div id="reg-27" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-27-val">s11 (x27)</label></div><div class="field-body is-expanded"><input id="reg-27-val" class="input is-small" onblur="driver.saveRegister(this, 27)" spellcheck="false"></div></div></div><div id="reg-28" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-28-val">t3 (x28)</label></div><div class="field-body is-expanded"><input id="reg-28-val" class="input is-small" onblur="driver.saveRegister(this, 28)" spellcheck="false"></div></div></div><div id="reg-29" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-29-val">t4 (x29)</label></div><div class="field-body is-expanded"><input id="reg-29-val" class="input is-small" onblur="driver.saveRegister(this, 29)" spellcheck="false"></div></div></div><div id="reg-30" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-30-val">t5 (x30)</label></div><div class="field-body is-expanded"><input id="reg-30-val" class="input is-small" onblur="driver.saveRegister(this, 30)" spellcheck="false"></div></div></div><div id="reg-31" class="panel-block"><div class="field is-horizontal"><div class="field-label"><label class="label is-small" for="reg-31-val">t6 (x31)</label></div><div class="field-body is-expanded"><input id="reg-31-val" class="input is-small" onblur="driver.saveRegister(this, 31)" spellcheck="false"></div></div></div></div><div id="memory-tab-view"><div class="panel-block"><table id="memory-table" class="table is-striped"><colgroup><col id="addr-column"><col id="byte0-column"><col id="byte1-column"><col id="byte2-column"><col id="byte3-column"></colgroup><thead><tr><th>Address</th><th>+0</th><th>+1</th><th>+2</th><th>+3</th></tr></thead><tr id="mem-row-6"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row-5"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row-4"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row-3"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row-2"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row-1"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row-0"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row--1"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row--2"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row--3"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row--4"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row--5"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr><tr id="mem-row--6"><td>0x00000000</td><td>0</td><td>0</td><td>0</td><td>0</td></tr></table></div><div class="panel-block"><div class="field is-horizontal"><div class="field-label is-normal"><label class="label">Jump to</label></div><div class="field-body"><div class="field is-narrow"><div class="control"><div class="select"><select id="address-jump" onchange="driver.moveMemoryJump()"><option value="" disabled selected hidden>-- choose --</option><option>Text</option><option>Data</option><option>Heap</option><option>Stack</option></select></div></div></div><div class="field"><div class="control"><input type="button" class="button" value="Up" onclick="driver.moveMemoryUp()"> <input type="button" class="button" value="Down" onclick="driver.moveMemoryDown()"></div></div></div></div></div></div></nav></article></div><div class="tile is-parent"><article class="tile is-child"><div class="field is-horizontal"><div class="field-label is-small"><label class="label">Display Settings</label></div><div class="field-body"><div class="control"><div class="field"><div class="select is-small"><select id="display-settings" onchange="driver.updateRegMemDisplay()"><option selected>Hex</option><option>Decimal</option><option>Unsigned</option><option>ASCII</option></select></div></div></div></div></div></article></div></div></div></div></section><script type="text/javascript" src="js/codemirror.js"></script><script type="text/javascript" src="venus.js"></script><script type="text/javascript">var driver = venus_main.venus.glue.Driver; | ||
var editor = document.getElementById("asm-editor"); | ||
var codeMirror = CodeMirror.fromTextArea(editor, | ||
{ | ||
lineNumbers: true, | ||
mode: "riscv", | ||
indentUnit: 4, | ||
autofocus: true, | ||
lint: true | ||
} | ||
); | ||
codeMirror.setSize("100%", "88vh");</script></body></html> |
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.