I've written a script and I want to direct the console output to a file, so I use this command:
~/simplesim-3.0/sim-cache -cache:dl1 dl1:1:64:2048:f -cache:il1 il1:1:64:2048:f \
-cache:il2 dl2 -cache:dl2 dl2:1:64:16384:f -tlb:itlb none \
-tlb:dtlb none cc1.alpha -O 1stmt.i 2>&1 | tee mkdir ./cc.txt
The part upto "1stmt.i" is a command for a simulation tool (Simplescalar). This works fine though. However when I try the same for a different command:
~/simplesim-3.0/sim-cache -cache:dl1 dl1:512:64:2:f -cache:il1 il1:512:64:2:f \
-cache:il2 dl2 -cache:dl2 dl2:16384:64:1:f -tlb:itlb none -tlb:dtlb none \
anagram.alpha words < anagram.in > OUT 2>&1 | tee mkdir ./cc3.txt
The file (cc3.txt) is an empty file. I don't understand why is the redirection not happening.