Add comprehensive performance metrics and data collection
- Added instructions, cycles, and IPC metrics to all reports - Created CSV data files for each language with detailed metrics - Added timeline data (memory and CPU over time) for each run - Updated all reports with new metrics - Created analysis script to analyze collected data - Generated reports for all decimal levels (1, 2, 5, 10, 100, 1000, 2000) Key findings: - D has highest IPC (4.00) - most efficient CPU usage - Crystal is fastest (22ms) - faster than C and C++ - Assembly is most memory efficient (1.4MB) - Rust and Fortran have IPC 3.11 - good optimization
This commit is contained in:
+25
-3
@@ -41,8 +41,8 @@ create_report() {
|
||||
|
||||
### All Languages
|
||||
|
||||
| Rank | Language | Time (ms) | Memory (bytes) | Type |
|
||||
|------|-----------|-----------|----------------|------|
|
||||
| Rank | Language | Time (ms) | Memory (bytes) | Instructions | Cycles | IPC | Type |
|
||||
|------|-----------|-----------|----------------|--------------|---------|-----|------|
|
||||
EOF
|
||||
|
||||
# Extract data and sort by time, then memory
|
||||
@@ -76,7 +76,29 @@ EOF
|
||||
type = "Interpreted"
|
||||
}
|
||||
|
||||
printf "| %d | %s | %s | %s | %s |\n", rank, lang, time, mem, type
|
||||
# Get instructions, cycles, and IPC from summary.csv
|
||||
summary_file = "data/" lang "/summary.csv"
|
||||
instructions = 0
|
||||
cycles = 0
|
||||
ipc = 0
|
||||
|
||||
while ((getline line < summary_file) > 0) {
|
||||
if (line ~ /^instructions,/) {
|
||||
split(line, arr, ",")
|
||||
instructions = arr[2]
|
||||
}
|
||||
if (line ~ /^cycles,/) {
|
||||
split(line, arr, ",")
|
||||
cycles = arr[2]
|
||||
}
|
||||
if (line ~ /^ipc,/) {
|
||||
split(line, arr, ",")
|
||||
ipc = arr[2]
|
||||
}
|
||||
}
|
||||
close(summary_file)
|
||||
|
||||
printf "| %d | %s | %s | %s | %s | %s | %.2f | %s |\n", rank, lang, time, mem, instructions, cycles, ipc, type
|
||||
}' >> "$output_file"
|
||||
|
||||
# Add detailed results section
|
||||
|
||||
Reference in New Issue
Block a user