Deleted Added
sdiff udiff text old ( 8232:b28d06a175be ) new ( 10880:61a56f76222b )
full compact
1/*
2 * Copyright (c) 2003-2005 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 35 unchanged lines hidden (view full) ---

44#include "arch/alpha/ecoff_machdep.h"
45#include "base/loader/coff_sym.h"
46#include "base/loader/coff_symconst.h"
47#include "base/loader/exec_ecoff.h"
48
49using namespace std;
50
51ObjectFile *
52EcoffObject::tryFile(const string &fname, size_t len, uint8_t *data)
53{
54 if (((ecoff_filehdr *)data)->f_magic == ECOFF_MAGIC_ALPHA) {
55 // it's Alpha ECOFF
56 return new EcoffObject(fname, len, data,
57 ObjectFile::Alpha, ObjectFile::Tru64);
58 }
59 else {
60 return NULL;
61 }
62}
63
64
65EcoffObject::EcoffObject(const string &_filename, size_t _len, uint8_t *_data,
66 Arch _arch, OpSys _opSys)
67 : ObjectFile(_filename, _len, _data, _arch, _opSys)
68{
69 execHdr = (ecoff_exechdr *)fileData;
70 fileHdr = &(execHdr->f);
71 aoutHdr = &(execHdr->a);
72
73 entry = aoutHdr->entry;
74
75 text.baseAddr = aoutHdr->text_start;

--- 85 unchanged lines hidden ---