Find Jobs
Hire Freelancers

C program (cache.c)

$10-30 USD

Terminado
Publicado hace casi 8 años

$10-30 USD

Pagado a la entrega
Project(C program) The main objective of this project is for you to learn about cache memories, their organization, and the impact of their design on program performance measured in terms of the memory subsystem. In this part, you will code a C program (cache.c), behaviorally simulating a single level cache. Your program will model a data cache with the following parameters • S: the number of sets in the cache • A: the associativity (or the number of entries in each set). • B: the block size in bytes • R: Replacement policy (R = 1 LRU, R=2 FIFO). • W: Write policy (W = 1) • -v Verbose Your program will support the command line switches to create a cache of the specified parameters. For example, loki> ./cache –S 512 –A 2 –B 32 –R 1 –W 1 -v should create 8KB 2-way associative cache, with LRU replacement policy and print the cache (because of verbose switch). Input: The input to your cache is a file containing memory trace of a C executable produced using the valgrind utility. For example, the following command should produce the trace for the program “ls”. linux> valgrind --log-fd=1 --tool=lackey -v --trace-mem=yes ls -l The memory trace file output by valgrind has the following format: I 0400d7d4,8 M 08,4 L 04f6b868,8 S 7ff0005c8,8 … Each line is of the form: [space]operation[space]address,size The operation I: is an instruction load, L: a data load, S: a data store, and M: a data modify (i.e., a data load followed by a data store). There is never a space before an “I” and there is always a space before each “M”, “L”, and “S”. The address field specifies a 64-bit hex memory address and the size field specifies the number of bytes accessed by the operation. Output: The program should print the cache in whatever format you choose when it is given a command line as described above. The program should output the number of hits, misses and the number of evictions when it is given a valgrind trace with a –t switch as follows. Below, [login to view URL] is the trace file obtained using valgrind on some executable example. linux> ./cache -S 16 -A 1 -B 4 –t [login to view URL] hits:4 misses:5 evictions:3
ID del proyecto: 10595487

Información sobre el proyecto

2 propuestas
Proyecto remoto
Activo hace 8 años

¿Buscas ganar dinero?

Beneficios de presentar ofertas en Freelancer

Fija tu plazo y presupuesto
Cobra por tu trabajo
Describe tu propuesta
Es gratis registrarse y presentar ofertas en los trabajos
Adjudicado a:
Avatar del usuario
Hi! I understand that the project is quite tough and $25 is very less for that. I would still be ready to help you out on this if you give me at least time till Sunday. You can check my reviews to know a bit about me and my skill set. Thanks!
$25 USD en 5 días
5,0 (7 comentarios)
3,0
3,0
2 freelancers están ofertando un promedio de $123 USD por este trabajo
Avatar del usuario
Embedded Developer, 9+ years, Linux Device Driver, Bootloaders, Board Bring-up Dear Sir/Madam, I have 9+ years experience in Embedded Development. I have experience in Linux device drivers, UEFI (Bootloader) development and Board Bring-up. I have knowledge of PCI, PCIe, Ethernet, USB, UART, and USB Host Controller (OTG).
$222 USD en 2 días
5,0 (1 comentario)
0,6
0,6
Avatar del usuario
I can start ur work immediately. I have 10 years experience in coding and development. I'm expert in writing programs in JAVA, .NET, C, C++ I have experience in hadoop,python coding, PHP Android Neo4j Hbase Nosql Nosql sql Oracle Mongodb Spark Hive Pig I can meet your requirements. Looking forward..
$111 USD en 2 días
0,0 (0 comentarios)
0,0
0,0

Sobre este cliente

Bandera de UNITED STATES
omaha, United States
5,0
4
Forma de pago verificada
Miembro desde abr 15, 2016

Verificación del cliente

¡Gracias! Te hemos enviado un enlace para reclamar tu crédito gratuito.
Algo salió mal al enviar tu correo electrónico. Por favor, intenta de nuevo.
Usuarios registrados Total de empleos publicados
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Cargando visualización previa
Permiso concedido para Geolocalización.
Tu sesión de acceso ha expirado y has sido desconectado. Por favor, inica sesión nuevamente.