Initial commit

This commit is contained in:
github-classroom[bot] 2023-09-22 18:29:55 +00:00 committed by GitHub
commit 92f533fba3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
17 changed files with 108 additions and 0 deletions

2
.idea/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
# Default ignored files
/workspace.xml

View File

@ -0,0 +1,5 @@
<component name="ProjectCodeStyleConfiguration">
<state>
<option name="PREFERRED_PROJECT_CODE_STYLE" value="Default" />
</state>
</component>

11
.idea/misc.xml Normal file
View File

@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ASMPluginConfiguration">
<asm skipDebug="false" skipFrames="false" skipCode="false" expandFrames="false" />
<groovy codeStyle="LEGACY" />
</component>
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES6" />
</component>
<component name="ProjectRootManager" version="2" project-jdk-name="1.8" project-jdk-type="JavaSDK" />
</project>

8
.idea/modules.xml Normal file
View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/starter-lab-01-java-and-c.iml" filepath="$PROJECT_DIR$/.idea/starter-lab-01-java-and-c.iml" />
</modules>
</component>
</project>

View File

View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

6
.idea/vcs.xml Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
</component>
</project>

34
README.md Normal file
View File

@ -0,0 +1,34 @@
# Lab 1 - Software Peformance 2023
This is Lab 1 of the **Software Performance** course at USI.
Go to [this Lab on iCorsi](https://www.icorsi.ch/course/view.php?id=16963).
## Submission Info
Property | Value
------------ | -------------
First Name | ...
Last Name | ...
## Submission Checklist
Please complete this checklist (turn [ ] into [X]) before you submit:
- [ ] I completed the above Submission Info
- [ ] I solved the Java part:
- [ ] I implemented the Java code
- [ ] I completed java/compile.sh
- [ ] I completed java/run.sh
- [ ] I completed java/disassemble.sh
- [ ] I solved the C part:
- [ ] I implemented the C code
- [ ] I completed c/compile.sh
- [ ] I completed c/run.sh
- [ ] I completed c/disassemble.sh
- [ ] I wrote the source code myself and did not look at the source code of my classmates
- [ ] I ran test/test.sh and verified that it produces the expected output
- [ ] I verified that the disassembled instructions appear (not just the function names)
- [ ] I committed my changes (at least one commit, but possibly many)
- [ ] I pushed my commits to GitHub

3
c/compile.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
# TODO Command to compile main.c with gcc

3
c/disassemble.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
# TODO Command to disassemble the compiled C program with otool

1
c/main.c Normal file
View File

@ -0,0 +1 @@
// TODO Write C code

3
c/run.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
# TODO Command to run the compiled C program

1
java/Main.java Normal file
View File

@ -0,0 +1 @@
//TODO Write Java code

3
java/compile.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
# TODO Command to compile Main.java with javac

3
java/disassemble.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
# TODO Command to disassemble the compiled Java program with javap

3
java/run.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
# TODO Command to run the compiled Java program with java

13
test/test.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/sh
echo Testing Java...
../java/compile.sh
../java/disassemble.sh
../java/run.sh
echo Testing C...
../c/compile.sh
../c/disassemble.sh
../c/run.sh