summaryrefslogtreecommitdiff
path: root/src/base/compression/null_compression.hh
diff options
context:
space:
mode:
authorLisa Hsu <hsul@eecs.umich.edu>2006-12-15 13:27:53 -0500
committerLisa Hsu <hsul@eecs.umich.edu>2006-12-15 13:27:53 -0500
commit991146218de5c0019fa6f97ef0f9742f1105ccb3 (patch)
tree194d336cdf736a7972c7fe4b36803a45d48a9a62 /src/base/compression/null_compression.hh
parent573d59441e420f02fd7cf3e31158258f5eee3ab1 (diff)
parenta10eff03a529ef79ac9481188cdaf01b269efe16 (diff)
downloadgem5-991146218de5c0019fa6f97ef0f9742f1105ccb3.tar.xz
Merge zizzer:/bk/sparcfs
into zed.eecs.umich.edu:/z/hsul/work/sparc/m5 --HG-- extra : convert_revision : 2f11b5f9fa6356cbf9f98c8cd7d4f6fbfaf9d24d
Diffstat (limited to 'src/base/compression/null_compression.hh')
-rw-r--r--src/base/compression/null_compression.hh28
1 files changed, 5 insertions, 23 deletions
diff --git a/src/base/compression/null_compression.hh b/src/base/compression/null_compression.hh
index 5a582d828..ff110807a 100644
--- a/src/base/compression/null_compression.hh
+++ b/src/base/compression/null_compression.hh
@@ -38,41 +38,23 @@
*/
#include "base/misc.hh" // for fatal()
-#include "sim/host.hh"
+#include "base/compression/base.hh"
/**
* A dummy compression class to use when no data compression is desired.
*/
-class NullCompression
+class NullCompression : public CompressionAlgorithm
{
public:
- /**
- * Uncompress the data, causes a fatal since no data should be compressed.
- * @param dest The output buffer.
- * @param src The compressed data.
- * @param size The number of bytes in src.
- *
- * @retval The size of the uncompressed data.
- */
- static int uncompress(uint8_t * dest, uint8_t *src, int size)
+ int uncompress(uint8_t * dest, uint8_t *src, int size)
{
fatal("Can't uncompress data");
}
- /**
- * Compress the data, just returns the source data.
- * @param dest The output buffer.
- * @param src The data to be compressed.
- * @param size The number of bytes in src.
- *
- * @retval The size of the compressed data.
- */
-
- static int compress(uint8_t *dest, uint8_t *src, int size)
+ int compress(uint8_t *dest, uint8_t *src, int size)
{
- memcpy(dest,src,size);
- return size;
+ fatal("Can't compress data");
}
};