Ejemplo n.º 1
0
int main()
{
	printf("Running EagleTree\n");
	set_small_SSD_config();
	string name  = "/demo_output/";
	Experiment::create_base_folder(name.c_str());
	Experiment* e = new Experiment();
	Workload_Definition* workload = new Example_Workload();
	e->set_workload(workload);
	e->set_io_limit(1000000);
	e->run("test");
	e->draw_graphs();
	delete workload;
	return 0;
}
Ejemplo n.º 2
0
int main()
{
	printf("Running EagleTree\n");
	set_small_SSD_config();
//	set_big_SSD_config();

	//gogo greedy
	// GARBAGE_COLLECTION_POLICY = 0;
	// string name  = "/greedy_demo_output/";

	// gogo LRU
	GARBAGE_COLLECTION_POLICY = 1;
	string name  = "/lru_demo_output/";

	//gogo dj
//		GARBAGE_COLLECTION_POLICY = 2;
//	string name  = "/demo_output_500/";


	FTL_DESIGN = 1;	// using DFTL
	SCHEDULING_SCHEME = 7;
	PRINT_LEVEL = 0;
	MAX_SSD_QUEUE_SIZE = 16;
	ftl_cache::CACHED_ENTRIES_THRESHOLD = pow(2,15);		// SRAM fitting 256 kb, or 2^25 entries,
	DFTL::ENTRIES_PER_TRANSLATION_PAGE = 128;

	Experiment::create_base_folder(name.c_str());
	Experiment* e = new Experiment();
	Workload_Definition* workload = new Example_Workload();
	e->set_workload(workload);
	printf("NUMBER_OF_ADDRESSABLE_PAGES: %d  %d\n", NUMBER_OF_ADDRESSABLE_PAGES(), (int)(NUMBER_OF_ADDRESSABLE_PAGES() * OVER_PROVISIONING_FACTOR));
	e->set_io_limit(3000000);
//	e->set_io_limit(30000000);
//	e->set_io_limit(pow(2,0));
	e->run("test");
	e->draw_graphs();
	delete workload;
	return 0;
}
Ejemplo n.º 3
0
int main()
{
	printf("Running EagleTree\n");
	set_small_SSD_config();
	string name  = "/demo_output/";
	Experiment::create_base_folder(name.c_str());
	Workload_Definition* init = new Init_Workload();
	string calibration_file = "calib.txt";
	SCHEDULING_SCHEME = 1; // use the noop IO scheduler during calibration because it's fastest in terms of real execution time
	Experiment::calibrate_and_save(init, calibration_file);
	delete init;
	Experiment* e = new Experiment();
	e->set_calibration_file(calibration_file);
	Workload_Definition* workload = new Asynch_Random_Workload();
	e->set_workload(workload);
	e->set_io_limit(1000000);
	SCHEDULING_SCHEME = 0; // use a fifo IO scheduler during the actual experiment
	e->run("test");
	e->draw_graphs();
	delete workload;
	return 0;
}
Ejemplo n.º 4
0
int main(int argc, char* argv[])
{
	printf("Running sequential!!\n");
	char* results_file = "";
	if (argc == 1) {
		printf("Setting big SSD config\n");
		set_big_SSD();
	}
	else if (argc == 3) {
		char* config_file_name = argv[1];
		printf("Setting config from file:  %s\n", config_file_name);
		results_file = argv[2];
		printf("results_file:  %s\n", results_file);
		load_config(config_file_name);
	}

	string name = "/exp_sequential/";
	string exp_folder = get_current_dir_name() + name;
	Experiment::create_base_folder(exp_folder.c_str());

	//set_big_SSD();
	//OVER_PROVISIONING_FACTOR = 0.70;

	Workload_Definition* workload = new File_System_With_Noise();

	OS_SCHEDULER = 1;
	vector<vector<Experiment_Result> > exps;


	Experiment* e = new Experiment();
	e->set_io_limit(200000);
	//e->set_generate_trace_file(true);
	if (argc == 1) {
		BLOCK_MANAGER_ID = 0;
		string no_locality_calibration_file = "no_locality_calibration_file.txt";
		Experiment::calibrate_and_save(workload, no_locality_calibration_file, 4 * NUMBER_OF_ADDRESSABLE_PAGES());
		e->set_calibration_file(no_locality_calibration_file);
		e->run("no_locality");

		BLOCK_MANAGER_ID = 2;
		ENABLE_TAGGING = true;
		string locality_calibration_file = "locality_calibration_file.txt";
		Experiment::calibrate_and_save(workload, locality_calibration_file);
		e->set_calibration_file(locality_calibration_file);
		e->run("locality");
	}
	else if (argc == 3 && BLOCK_MANAGER_ID == 0) {
		printf("running no locality\n");
		string no_locality_calibration_file = "no_locality_calibration_file.txt";
		e->set_calibration_file(no_locality_calibration_file);
		e->set_alternate_location_for_results_file(results_file);
		e->run("no_locality");
	}
	else if (argc == 3 && BLOCK_MANAGER_ID == 2) {
		printf("running locality\n");
		string locality_calibration_file = "locality_calibration_file.txt";
		e->set_calibration_file(locality_calibration_file);
		e->set_alternate_location_for_results_file(results_file);
		e->run("locality");
	}
	e->draw_graphs();


	delete workload;
	delete e;
	//BLOCK_MANAGER_ID = 3;
	//ENABLE_TAGGING = true;
	//Experiment_Runner::calibrate_and_save(workload, true);
	//vector<Experiment_Result> er = Experiment::simple_experiment(workload, "sequential", IO_limit, OVER_PROVISIONING_FACTOR, space_min, space_max, space_inc);
	//exps.push_back(er);

	//exp.push_back( Experiment_Runner::overprovisioning_experiment(detection_LUN, 	space_min, space_max, space_inc, exp_folder + "seq_detect_lun/",	"Seq Detect: LUN", IO_limit) );
	//exp.push_back( Experiment_Runner::simple_experiment(experiment, Init_Workload, space_min, space_max, space_inc, exp_folder + "oracle/",			"Oracle", IO_limit) );
	//exp.push_back( Experiment_Runner::overprovisioning_experiment(shortest_queues,	space_min, space_max, space_inc, exp_folder + "shortest_queues/",	"Shortest Queues", IO_limit) );

	/*Experiment_Runner::draw_graphs(exps, exp_folder);
	vector<int> num_write_thread_values_to_show;
	for (double i = space_min; i <= space_max; i += space_inc)
		num_write_thread_values_to_show.push_back(i); // Show all used spaces values in multi-graphs

	Experiment_Runner::draw_experiment_spesific_graphs(exps, exp_folder, num_write_thread_values_to_show);
	chdir(".."); // Leaving*/
	return 0;
}