summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTim Besard <tim.besard@gmail.com>2011-11-02 09:14:28 +0100
committerTim Besard <tim.besard@gmail.com>2011-11-02 09:14:28 +0100
commitacaf9d22fe2d7ad7101ba2bf474478e9b7b5d2af (patch)
tree4f27c518397708db8ee7586e4ac124421f6bd76c /src
parentc108197c20aa7b93849e383a3aaaf7b2bba30405 (diff)
Removing redundant main headers.
Diffstat (limited to 'src')
-rw-r--r--src/Main.c94
-rw-r--r--src/Main.cpp2
-rw-r--r--src/Main.h18
3 files changed, 0 insertions, 114 deletions
diff --git a/src/Main.c b/src/Main.c
deleted file mode 100644
index 3a2ec10..0000000
--- a/src/Main.c
+++ /dev/null
@@ -1,94 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 International Business Machines Corporation. *
- * All rights reserved. This program and the accompanying materials *
- * are made available under the terms of the Common Public License v1.0 *
- * which accompanies this distribution, and is available at *
- * http://www.opensource.org/licenses/cpl1.0.php *
- * *
- * Contributors: *
- * Douglas M. Pase - initial API and implementation *
- *******************************************************************************/
-
-#include <stdio.h>
-
-#include "Main.h"
-
-#include "Run.h"
-#include "Timer.h"
-#include "Types.h"
-#include "Output.h"
-#include "Experiment.h"
-#include "SpinBarrier.h"
-
-// This program allocates and accesses
-// a number of blocks of memory, one or more
-// for each thread that executes. Blocks
-// are divided into sub-blocks called
-// pages, and pages are divided into
-// sub-blocks called cache lines.
-//
-// All pages are collected into a list.
-// Pages are selected for the list in
-// a particular order. Each cache line
-// within the page is similarly gathered
-// into a list in a particular order.
-// In both cases the order may be random
-// or linear.
-//
-// A root pointer points to the first
-// cache line. A pointer in the cache
-// line points to the next cache line,
-// which contains a pointer to the cache
-// line after that, and so on. This
-// forms a pointer chain that touches all
-// cache lines within the first page,
-// then all cache lines within the second
-// page, and so on until all pages are
-// covered. The last pointer contains
-// NULL, terminating the chain.
-//
-// Depending on compile-time options,
-// pointers may be 32-bit or 64-bit
-// pointers.
-
-int verbose = 0;
-
-int main(int argc, char* argv[]) {
- Timer
- ::calibrate(10000);
- double clk_res = Timer
- ::resolution();
-
- Experiment e;
- if (e.parse_args(argc, argv)) {
- return 0;
- }
-
-#if defined(UNDEFINED)
- e.print();
- if (argv != NULL) return 0;
-#endif
-
- SpinBarrier
- sb(e.num_threads);
- Run r[e.num_threads];
- for (int i = 0; i < e.num_threads; i++) {
- r[i].set(e, &sb);
- r[i].start();
- }
-
- for (int i = 0; i < e.num_threads; i++) {
- r[i].wait();
- }
-
- int64
- ops = Run
- ::ops_per_chain();
- double secs = Run
- ::seconds();
-
- Output
- ::print(e, ops, secs, clk_res);
-
- return 0;
-}
diff --git a/src/Main.cpp b/src/Main.cpp
index a4d68e4..ccdaef8 100644
--- a/src/Main.cpp
+++ b/src/Main.cpp
@@ -11,8 +11,6 @@
#include <stdio.h>
-#include "Main.h"
-
#include "Run.h"
#include "Timer.h"
#include "Types.h"
diff --git a/src/Main.h b/src/Main.h
deleted file mode 100644
index 1492291..0000000
--- a/src/Main.h
+++ /dev/null
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 International Business Machines Corporation. *
- * All rights reserved. This program and the accompanying materials *
- * are made available under the terms of the Common Public License v1.0 *
- * which accompanies this distribution, and is available at *
- * http://www.opensource.org/licenses/cpl1.0.php *
- * *
- * Contributors: *
- * Douglas M. Pase - initial API and implementation *
- *******************************************************************************/
-
-
-#if !defined(Main_h)
-#define Main_h
-
-extern int verbose;
-
-#endif