Commit Graph

194 Commits (f82c42a22e6a0883c8b51b269d3be9c50e4cd6be)

Author SHA1 Message Date
Russell Bryant 248dac6e73 Fix the build of astman. Any file that includes any asterisk sub-headers
18 years ago
Kevin P. Fleming 93615ecc22 let's try this again... *all* compilation and linking in Asterisk should be done using the standard compilation rules, not manually created ones. changing hashtest.c to use these rules caused the compiler to notice a large number of coding guidelines violations, so those are fixed too.
18 years ago
Steve Murphy 4c992507f4 closes issue #11341; made changes to make utils again right with the MTX_PROFILE world.
18 years ago
Luigi Rizzo 6dfc36b639 enable support for stack backtrace for stuff built in utils/
18 years ago
Kevin P. Fleming 3826d15993 move these forward declarations back to asterisk.h where they belong... even though asterisk.h includes compat.h, these declarations have nothing to do with the being platform-compatible and are directly related to being part of Asterisk
18 years ago
Luigi Rizzo 04e1e0069f more header removal/normalization
18 years ago
Luigi Rizzo b693c30a66 move the declaration of struct ast_channel ast_frame and ast_module
18 years ago
Luigi Rizzo 7cd78079ae more cygwin/mingw32 compatibility fixes
18 years ago
Luigi Rizzo 91475fd3dc add a return NULL to a function that is expected to return a value
18 years ago
Luigi Rizzo d82a631f9c more removal of duplicate #include lines
18 years ago
Luigi Rizzo 4afe3b5ba9 remove redundant #include "asterisk/compat.h",
18 years ago
Luigi Rizzo fdb7f7ba3d Start untangling header inclusion in a way that does not affect
18 years ago
Steve Murphy f033e50a15 Don't forget the ASTERISK_VERSION for the sake of the mtx_prof stuff.
18 years ago
Kevin P. Fleming c7773aa206 (closes issue #11221)
18 years ago
Joshua Colp 098728eb64 Fix building on FreeBSD by including/not including some headers.
18 years ago
Steve Murphy a897556f7f This is the perhaps the biggest, boldest, most daring change I've ever committed to trunk. Forgive me in advance any disruption this may cause, and please, report any problems via the bugtracker. The upside is that this can speed up large dialplans by 20 times (or more). Context, extension, and priority matching are all fairly constant-time searches. I introduce here my hashtables (hashtabs), and a regression for them. I would have used the ast_obj2 tables, but mine are resizeable, and don't need the object destruction capability. The hashtab stuff is well tested and stable. I introduce a data structure, a trie, for extension pattern matching, in which knowledge of all patterns is accumulated, and all matches can be found via a single traversal of the tree. This is per-context. The trie is formed on the first lookup attempt, and stored in the context for future lookups. Destruction routines are in place for hashtabs and the pattern match trie. You can see the contents of the pattern match trie by using the 'dialplan show' cli command when 'core set debug' has been done to put it in debug mode. The pattern tree traversal only traverses those parts of the tree that are interesting. It uses a scoreboard sort of approach to find the best match. The speed of the traversal is more a function of the length of the pattern than the number of patterns in the tree. The tree also contains the CID matching patterns. See the source code comments for details on how everything works. I believe the approach general enough that any issues that might come up involving fine points in the pattern matching algorithm, can be solved by just tweaking things. We shall see. The current pattern matcher is fairly involved, and replicating every nuance of it is difficult. If you find and report problems, I will try to resolve than as quickly as I can. The trie and hashtabs are added to the existing context and exten structs, and none of the old machinery has been removed for the sake of the multitude of functions that use them. In the future, we can (maybe) weed out the linked lists and save some space.
18 years ago
Kevin P. Fleming edc78d6023 improve linked-list macros in two ways:
18 years ago
Luigi Rizzo 1c55f8424e Move AUDIO_LIBS outside the top level Makefile. This too is used only
18 years ago
Tilghman Lesher e8c781b215 Add pbx_lua as a method of doing extensions
18 years ago
Steve Murphy 63f2f04cf4 This commits the performance mods that give the priority processing engine in the pbx, a 25-30% speed boost. The two updates used, are, first, to merge the ast_exists_extension() and the ast_spawn_extension() where they are called sequentially in a loop in the code, into a slightly upgraded version of ast_spawn_extension(), with a few extra args; and, second, I modified the substitute_variables_helper_full, so it zeroes out the byte after the evaluated string instead of demanding you pre-zero the buffer; I also went thru the code and removed the code that zeroed this buffer before every call to the substitute_variables_helper_full. The first fix provides about a 9% speedup, and the second the rest. These figures come from the 'PIPS' benchmark I describe in blogs, conf. reports, etc.
18 years ago
Russell Bryant cac97aa8b4 Remove another copied source file on "make clean".
18 years ago
Kevin P. Fleming 6ab27c871a UGH... while trying to fix #10995, I found all kinds of cruft in this Makefile. It should all be gone now, and as a side effect hashtest2 now builds with --enable-dev-mode enabled without a host of errors
18 years ago
Kevin P. Fleming a4b8ca220d clean up assembler and preprocessor files if they are here too
18 years ago
Steve Murphy c9f3efc381 Merged revisions 87168 via svnmerge from
18 years ago
Steve Murphy a69abc0179 and then, I noticed the clicompat stuff.
18 years ago
Steve Murphy e5fa15d812 more stub routines to allow linkage in stand-alone environment, with thread debugs turned on
18 years ago
Steve Murphy 65786f15fa more stub routines to allow linkage in stand-alone environment, with thread debugs turned on
18 years ago
Tilghman Lesher 7adbd6bb16 Remove redundant includes (patch by snuffy) (Closes issue #10922)
18 years ago
Joshua Colp 648f67d4c8 Fix up tree so that it compiles when MTX Profiling is enabled.
18 years ago
Steve Murphy 0d2ee300e7 OK. THis a DEBUG_THREADS situation.
18 years ago
Steve Murphy e8c8bb4a14 picky gcc versions... sigh.
18 years ago
Steve Murphy db26685460 This mod will allow check_expr to compile in the presence of DEBUG_THREAD situations. At least, it does for me. And it's less expensive than several other approaches I tried.
18 years ago
Russell Bryant 437b439c61 Add some files to the utils directory svn:ignore and Makefile clean target
18 years ago
Tilghman Lesher 1b949d24c0 Fix build of check_expr and hashtest2 when DEBUG_THREADLOCAL is defined
18 years ago
Russell Bryant 9f64905d4e Merged revisions 83432 via svnmerge from
18 years ago
Russell Bryant 99fb378cdc Change the traversal to use ao2_callback() instead of an ao2_iterator. Using
18 years ago
Steve Murphy c88e216a14 This solves an unreported solaris compile problem (missing -lnsl -lsocket).
18 years ago
Steve Murphy 26d739ff5b fixing up the pthread stuff for hashtest2
18 years ago
Joshua Colp 56a31d1d20 Include string compatibility file in hashtest2.
18 years ago
Joshua Colp c81d14226a Include compat.h to hopefully make it compatible with FreeBSD.
18 years ago
Joshua Colp 219470dc43 Fix building under FreeBSD. Make sure alloca.h exists before including it.
18 years ago
Steve Murphy c4133cc03f Committing my test for astobj2, hashtest2.c, along with makefile changes in utils.
18 years ago
Steve Murphy b5cd67adc3 This code was in team/murf/bug8684-trunk; it should fix bug 8684 in trunk. I didn't add it to 1.4 yet, because it's not entirely clear to me if this is a bug fix or an enhancement. A lot of files were affected by small changes like ast_variable_new getting an added arg, for the file name the var was defined in; ast_category_new gets added args of filename and lineno; ast_category and ast_variable structures now record file and lineno for each entry; a list of all #include and #execs in a config file (or any of its inclusions are now kept in the ast_config struct; at save time, each entry is put back into its proper file of origin, in order. #include and #exec directives are folded in properly. Headers indicating that the file was generated, are generated also for each included file. Some changes to main/manager.c to take care of file renaming, via the UpdateConfig command. Multiple inclusions of the same file are handled by exploding these into multiple include files, uniquely named. There's probably more, but I can't remember it right now.
18 years ago
Steve Murphy 088d7ef8bc fix up the MODULEINFO in conf2ael.c as well
18 years ago
Russell Bryant 6814e7b77e Merged revisions 80722 via svnmerge from
18 years ago
Steve Murphy 6419bd36ba Merged revisions 80717 via svnmerge from
18 years ago
Russell Bryant 483c2bad07 Ensure that the object code for ast_atomic_fetchadd_int() gets included in the
18 years ago
Steve Murphy b69734ae09 Stephn Davies reports that this will help make things work on 64-bit machines
18 years ago
Steve Murphy a9f86a939e pval.c should not be in svn, in the utils dir
18 years ago
Joshua Colp 4edcf623f0 Bring pval.c in utils up to date with pval.c in res/ael.
18 years ago