summaryrefslogtreecommitdiff
path: root/malloc.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove HAS_64K_LIMITBrian Fraser2013-09-211-10/+1
| | | | | | This was only defined for MSDOS if not using DJGPP. We've long since dropped support for that, so this define and related code can go.
* add adjust_size_and_find_bucket to embed.fncLukas Mai2013-08-111-5/+9
|
* Function name typo in malloc.cSergey Alekseev2013-08-101-3/+3
| | | | | | Error was also spotted by mauke. For: RT #119213
* Remove "register" declarationsKarl Williamson2012-11-241-3/+3
| | | | | | | This finishes the removal of register declarations started by eb578fdb5569b91c28466a4d1939e381ff6ceaf4. It neglected the ones in function parameter declarations, and didn't include things in dist, ext, and lib, which this does include
* Restore mymalloc build with ithreadsSteve Hay2012-09-211-0/+1
| | | | Broken by commit 7cd83f6573.
* Out of memory message should not allocate memory.Craig A. Berry2012-09-081-23/+20
| | | | | | | | | | | | This fixes [perl #40595]. When Perl_malloc reports an out of memory error, it should not make calls to PerlIO functions that may turn around and allocate memory using Perl_malloc. A simple write() should be ok, though. Inspired by S_write_no_mem() from util.c. Also replaces the local write2 function, which did the same thing slightly differently. Under -DDEBUGGING, there are other calls to PerlIO_printf that are also likely unsafe, but that problem is not addressed here.
* Omnibus removal of register declarationsKarl Williamson2012-08-181-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This removes most register declarations in C code (and accompanying documentation) in the Perl core. Retained are those in the ext directory, Configure, and those that are associated with assembly language. See: http://stackoverflow.com/questions/314994/whats-a-good-example-of-register-variable-usage-in-c which says, in part: There is no good example of register usage when using modern compilers (read: last 10+ years) because it almost never does any good and can do some bad. When you use register, you are telling the compiler "I know how to optimize my code better than you do" which is almost never the case. One of three things can happen when you use register: The compiler ignores it, this is most likely. In this case the only harm is that you cannot take the address of the variable in the code. The compiler honors your request and as a result the code runs slower. The compiler honors your request and the code runs faster, this is the least likely scenario. Even if one compiler produces better code when you use register, there is no reason to believe another will do the same. If you have some critical code that the compiler is not optimizing well enough your best bet is probably to use assembler for that part anyway but of course do the appropriate profiling to verify the generated code is really a problem first.
* Remove code for supporting 80286 based systems.Nicholas Clark2012-07-281-14/+2
| | | | | | | | The 80286 was released two years before Perl 1, but the support code was added with Perl 3. The chip hasn't been produced for more than 15 years - even the 80386 hasn't been manufactured since 2007. Most of the other memory model code was removed by commit 5869b1f143426909 in Sep 2000, so support for 16 bit systems is long dead.
* Remove dead code related to the Atari ST port of perl 4.0 patchlevel 19Nicholas Clark2012-07-281-5/+3
| | | | | The subdirectory containing the port specific files was purged when 5.000 was released, but changes made to other files were not removed.
* fix compile warnings in malloc.c [perl #75340]Jesse Luehrs2012-07-031-2/+2
|
* Use assertions for /* NOT REACHED */Father Chrysostomos2012-06-151-1/+1
| | | | to make sure it really is never reached.
* update the editor hints for spaces, not tabsRicardo Signes2012-05-291-2/+2
| | | | | This updates the editor hints in our files for Emacs and vim to request that tabs be inserted as spaces.
* Remove "support" for using malloc.c outside the perl core distribution.Nicholas Clark2011-12-091-224/+20
| | | | | | | | | | | | | | It only ever worked properly in 5.005. Commit d720c4410d3a0730 from June 1998 is the first known version of malloc.c that would compile stand alone, without needing a config.h Commit 5bbd1ef51ee0ebfa from December 1998 will not compile by default, but will if one provides suitable definitions of simple macros on the command line. Commit 427181846486e3aa from September 1999 will not compile with command line flags alone. 12 years later, no-one has reported problems, so it's safe to remove this.
* Remove commented-out "support" for perl's malloc with x2p.Nicholas Clark2011-12-091-5/+2
| | | | | | | | | | In 1998 commit 30e2e4257067d5f8 stated temporarily disable perl malloc for a2p until we clean up conflicting malloc() declarations everywhere and nothing has changed since. 13 years later, no-one has reported problems, so it's safe to remove it.
* Convert some files from Latin-1 to UTF-8Keith Thompson2011-09-071-1/+1
|
* Remove WITH_THR() and WITH_THX(), which are not used.Nicholas Clark2011-09-041-1/+0
| | | | | | | | | | | | grep.cpan.me and Google's codesearch find no use of WITH_THR or WITH_THX. WITH_THX() was added in June 1999 in cea2e8a9dd23747f, and the last user eliminated with 0b250b9ef0d5134f in August 1999. WITH_THX() was used again for DEBUG_CX() in 1c98cc53150c4860, and eliminated in d9f81b50694a810f. WITH_THR() was added in 1997 in 0f15f207c55ce70f. Use everywhere except DEBUG_SCOPE() was eliminated in 2006 in 11206fddaf7ef068. WITH_THR() was removed from DEBUG_SCOPE() in d9f81b50694a810f.
* Fix typos (spelling errors) in Perl sources.Peter J. Acklam) (via RT2011-01-071-4/+4
| | | | | | | | | # New Ticket Created by (Peter J. Acklam) # Please include the string: [perl #81904] # in the subject line of all future correspondence about this issue. # <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=81904 > Signed-off-by: Abigail <abigail@abigail.be>
* Add Perl_ck_warner_d(), which combines Perl_ckwarn_d() and Perl_warner().Nicholas Clark2009-10-121-14/+14
| | | | | Replace ckWARN_d{,2,3,4}() && Perl_warner() with it, which trades reduced code size for 1 more function call if warnings are not enabled.
* Removed vestigal support for Tenon Intersystems MachTen Unix layer for MacOS ↵Jesse Vincent2009-08-031-3/+3
| | | | | | Classic. Perl hasn't supported MachTen since 5.6.
* Remove the port to MiNT. It's a dead platform that hasn't had any love ↵Jesse Vincent2009-08-031-4/+4
| | | | since 5.005
* PATCH: Large omnibus patch to clean up the JRRT quotesTom Christiansen2008-11-021-1/+3
| | | | | | Message-ID: <25940.1225611819@chthon> Date: Sun, 02 Nov 2008 01:43:39 -0600 p4raw-id: //depot/perl@34698
* Make C++ compilers happy #5: jump to 'do_write' crossedMarcus Holland-Moritz2008-10-251-4/+4
| | | | | | | initialization in dTHX. Plus some consting, which also makes C++ happier. p4raw-id: //depot/perl@34579
* Fix malloc.c warningJerry D. Hedden2008-06-231-1/+1
| | | | | | From: "Jerry D. Hedden" <jdhedden@cpan.org> Message-ID: <1ff86f510806230641x37afed4bla697e381b3ba9d6d@mail.gmail.com> p4raw-id: //depot/perl@34078
* Re: [perl #46381] "Out of memory ... sbrk()" on FreeBSD-6.x for v.5.8.x but ↵Slaven Rezic2008-06-211-0/+2
| | | | | | | not v.5.6.x Message-ID: <874pgd6hxs.fsf@biokovo-amd64.herceg.de> p4raw-id: //depot/perl@34076
* Silence warning introduced by #32703 when building with MYMALLOCSteve Hay2008-03-061-1/+1
| | | p4raw-id: //depot/perl@33450
* [perl #46957] [PATCH] make Devel::Peek::mstat always availablesrezic@cpan.org2008-03-031-0/+4
| | | | | | From: srezic@cpan.org (via RT) <perlbug-followup@perl.org> Message-ID: <rt-3.6.HEAD-4732-1193510037-297.46957-75-0@perl.org> p4raw-id: //depot/perl@33414
* Add Perl_malloc_good_size to malloc.c. (A routine that rounds up the Nicholas Clark2008-02-271-16/+34
| | | | | | passed in request to the size that will actually be allocated. It's the same interface as Darwin already provides with malloc_good_size().) p4raw-id: //depot/perl@33389
* assert() that every NN argument is not NULL. Otherwise we have theNicholas Clark2008-02-121-0/+7
| | | | | | | | | | | | ability to create landmines that will explode under someone in the future when they upgrade their compiler to one with better optimisation. We've already done this at least twice. (Yes, some of the assertions are after code that would already have SEGVd because it already deferences a pointer, but they are put in to make it easier to automate checking that each and every case is covered.) Add a tool, checkARGS_ASSERT.pl, to check that every case is covered. p4raw-id: //depot/perl@33291
* Purge all use of Nullch in non-dual life modules.Nicholas Clark2008-01-231-3/+0
| | | | | Exterminate! Exterminate! Exterminate! p4raw-id: //depot/perl@33052
* get rid of warning due to empty dangling else in malloc.cDave Mitchell2007-04-151-1/+2
| | | p4raw-id: //depot/perl@30964
* Changes to get perl to compile with g++ on Cygwin. Some additionalSteve Peters2006-10-301-4/+4
| | | | | changes will be needed to get it to link though. p4raw-id: //depot/perl@29142
* two [PATCH]es: dVAR for malloc.c, and a signed/unsigned char*Jarkko Hietaniemi2006-04-281-0/+6
| | | | | Message-ID: <4452594B.4040609@gmail.com> p4raw-id: //depot/perl@28007
* Patch from Jarkko to fix breakage caused by change #27649Steve Hay2006-04-071-1/+1
| | | | | | see: http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2006-04/msg00144.html p4raw-link: @27649 on //depot/perl: 9ddc1e7af8675795ad0346c1274fd40d4096c50f p4raw-id: //depot/perl@27735
* Redo PERL_UNUSED_DECLAndy Lester2006-03-311-1/+1
| | | | | Message-ID: <20060331065458.GA28571@petdance.com> p4raw-id: //depot/perl@27649
* Re: [PATCH] s/Null(av|ch)/NULL/gSteven Schubiger2006-02-021-5/+5
| | | | | Message-ID: <20060202093849.GD12591@accognoscere.homeunix.org> p4raw-id: //depot/perl@27054
* hv_fetchs() supportAndy Lester2006-01-061-2/+2
| | | | | Message-ID: <20060106155719.GB9035@petdance.com> p4raw-id: //depot/perl@26676
* Re: [PATCH] Random constings and printf cleanupAndy Lester2005-10-051-1/+1
| | | | | Message-ID: <20051004201605.GA31682@petdance.com> p4raw-id: //depot/perl@25693
* Remove the n_aNicholas Clark2005-06-081-2/+1
| | | p4raw-id: //depot/perl@24762
* Random constingAndy Lester2005-06-031-4/+4
| | | | | Message-ID: <20050602171943.GA16553@petdance.com> p4raw-id: //depot/perl@24689
* Quotes fixed, see also perl #36079Andy Lester2005-06-021-4/+4
| | | | | Message-ID: <20050602050238.GA4001@petdance.com> p4raw-id: //depot/perl@24666
* Updated lint infrastructureAndy Lester2005-05-261-14/+12
| | | | | Message-ID: <20050525173139.GB1701@petdance.com> p4raw-id: //depot/perl@24580
* Attribute configurationAndy Lester2005-05-201-1/+1
| | | | | Message-ID: <20050519173256.GA29039@petdance.com> p4raw-id: //depot/perl@24508
* consting-eleventy.patch: More consts, plus actual bug fixAndy Lester2005-05-161-4/+4
| | | | | Message-ID: <20050516151353.GA25387@petdance.com> p4raw-id: //depot/perl@24489
* Include vim/emacs modelines in generated files to open themRafael Garcia-Suarez2005-05-111-2/+2
| | | | | | in read-only mode. Make vi modelines compatible with non-vim vi versions. p4raw-id: //depot/perl@24445
* Add editor boilerplates to all C filesRafael Garcia-Suarez2005-05-101-0/+10
| | | | | (except the generated ones) p4raw-id: //depot/perl@24440
* Refactoring to Sv*_set() macros - patch #6Steve Peters2005-04-201-1/+2
| | | | | | Message-ID: <20050420112720.GA31042@mccoy.peters.homeunix.org> Date: Wed, 20 Apr 2005 06:27:20 -0500 p4raw-id: //depot/perl@24260
* Refactoring to Sv*_set() macros - patch #4Steve Peters2005-04-181-1/+1
| | | | | | | Message-ID: <20050416160502.GA26957@mccoy.peters.homeunix.org> plus fix to Perl_rvpv_dup assigning to an RV with SvPVX p4raw-id: //depot/perl@24239
* Another Win32 compilation clean-up (for when using Perl's malloc)Steve Hay2005-03-311-4/+5
| | | p4raw-id: //depot/perl@24108
* Add comment to the top of most .c files explaining their purposeDave Mitchell2004-07-311-0/+6
| | | p4raw-id: //depot/perl@23176
* Encourage compilers to tail call optimise in sv_savepv, sv_savepvnNicholas Clark2004-07-161-2/+2
| | | | | | and sv_savesharedpv. Need to create non-void returning versions of Copy and Zero, as the existing macros deliberately cast to (void) p4raw-id: //depot/perl@23126