From 7c0d3032f3e51e7bcd662a12b94c92d5c93a8e4b Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Mon, 4 Mar 1996 20:32:53 +0000 Subject: [PATCH] Changes to allow microcode to be compiled by the Linux ELF gcc. --- v7/src/microcode/cmpauxmd/i386.m4 | 11 +++-------- v7/src/microcode/config.h | 28 ++-------------------------- 2 files changed, 5 insertions(+), 34 deletions(-) diff --git a/v7/src/microcode/cmpauxmd/i386.m4 b/v7/src/microcode/cmpauxmd/i386.m4 index 936182e13..16742d7eb 100644 --- a/v7/src/microcode/cmpauxmd/i386.m4 +++ b/v7/src/microcode/cmpauxmd/i386.m4 @@ -1,8 +1,8 @@ ### -*-Midas-*- ### -### $Id: i386.m4,v 1.43 1995/10/30 07:52:35 cph Exp $ +### $Id: i386.m4,v 1.44 1996/03/04 20:31:56 cph Exp $ ### -### Copyright (c) 1992-95 Massachusetts Institute of Technology +### Copyright (c) 1992-96 Massachusetts Institute of Technology ### ### This material was developed by the Scheme project at the ### Massachusetts Institute of Technology, Department of @@ -146,8 +146,7 @@ ### switched between the two automatically. Currently works only ### for Win32s. ### LINUX_ELF -### If defined, expand to run under Linux ELF. This is the -### remains of a failed experiment; do NOT define this symbol. +### If defined, expand to run under Linux ELF. ### TYPE_CODE_LENGTH ### Normally defined to be 6. Don't change this unless you know ### what you're doing. @@ -414,7 +413,6 @@ define_data(C_Frame_Pointer) allocate_longword(C_Frame_Pointer) IF_WIN32(`define(HACK_SEGMENT_REGS,1)') -IF_LINUX_ELF(`define(HACK_SEGMENT_REGS,1)') ifdef(`HACK_SEGMENT_REGS',` @@ -443,10 +441,7 @@ define_data(C_Stack_Segment_Selector) allocate_word(C_Stack_Segment_Selector) IF_WIN32(`define(LRET,`db 0cbh')') -IF_LINUX_ELF(`define(LRET,`lret')') - IF_WIN32(`define(SEGMENT_DELTA,`EVR(winnt_address_delta)')') -IF_LINUX_ELF(`define(SEGMENT_DELTA,`IMM(0x08000000)')') ',`IFDOS(` diff --git a/v7/src/microcode/config.h b/v7/src/microcode/config.h index d050f5dc9..0722ba5a8 100644 --- a/v7/src/microcode/config.h +++ b/v7/src/microcode/config.h @@ -1,8 +1,8 @@ /* -*-C-*- -$Id: config.h,v 9.94 1995/10/24 04:55:32 cph Exp $ +$Id: config.h,v 9.95 1996/03/04 20:32:53 cph Exp $ -Copyright (c) 1987-95 Massachusetts Institute of Technology +Copyright (c) 1987-96 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -463,30 +463,6 @@ extern unsigned long winnt_address_delta; #endif /* WINNT && !WINNT_RAW_ADDRESSES */ -#ifdef _LINUX_ELF - -/* Linux ELF adds a data-segment bit which must be translated away. - We'll use the same trick as Win32s since the code is there and it - maintains binary compatibility. */ - -#define LINUX_ELF_DATA_SEGMENT_START 0x08000000 -#define LINUX_ELF_DATA_SEGMENT_LIMIT 0x04000 - -#define DATUM_TO_ADDRESS(datum) \ - ((SCHEME_OBJECT *) \ - (((unsigned long) (datum)) + LINUX_ELF_DATA_SEGMENT_START)) - -#define ADDRESS_TO_DATUM(address) \ - ((SCHEME_OBJECT) \ - (((unsigned long) (address)) - LINUX_ELF_DATA_SEGMENT_START)) - -typedef unsigned long SCHEME_ADDR; -#define SCHEME_ADDR_TO_ADDR(saddr) (DATUM_TO_ADDRESS (saddr)) -#define ADDR_TO_SCHEME_ADDR(caddr) (ADDRESS_TO_DATUM (caddr)) -#define HOOK_TO_SCHEME_OFFSET(hook) (ADDRESS_TO_DATUM (hook)) - -#endif /* __linux && __ELF__ */ - #endif /* i386 */ #ifdef mips -- 2.25.1