run_in_graphene.awk 1.1 KB

123456789101112131415161718192021222324252627282930
  1. #!/usr/bin/awk -f
  2. #
  3. # Script for adding necessary valgrind calls before commands.
  4. #
  5. # Copyright (C) 2016 Stony Brook University.
  6. # This file is part of Graphene library OS.
  7. #
  8. # This program is free software; you can redistribute it and/or modify
  9. # it under the terms of the GNU Lesser General Public License as published by
  10. # the Free Software Foundation; either version 2 of the License, or
  11. # (at your option) any later version.
  12. #
  13. # This program is distributed in the hope that it will be useful,
  14. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. # GNU Lesser General Public License for more details.
  17. #
  18. # You should have received a copy of the GNU Lesser General Public License along
  19. # with this program; if not, write to the Free Software Foundation, Inc.,
  20. # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  21. #
  22. # Chia-Che Tsai, Fall 2016
  23. #
  24. NF && ! /^#/ && ! /epoll/ {
  25. s=$1 "_graphene ./pal_loader"
  26. for (i = 2; i <= NF; i++) {
  27. s = s " " $i
  28. }
  29. print s
  30. }